2021-01-18 22:50:56 -08:00
|
|
|
{ lib, stdenv, fetchFromGitHub, mono, gtk-sharp-2_0, pkg-config, makeWrapper, gnome2, gtk2 }:
|
2019-08-13 14:52:01 -07:00
|
|
|
stdenv.mkDerivation {
|
2015-08-15 15:05:29 -07:00
|
|
|
version = "git-2014-08-20";
|
2019-08-15 05:41:18 -07:00
|
|
|
pname = "supertux-editor";
|
2015-08-15 15:05:29 -07:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "SuperTux";
|
|
|
|
repo = "supertux-editor";
|
|
|
|
rev = "0c666e8ccc7daf9e9720fe79abd63f8fa979c5e5";
|
|
|
|
sha256 = "08y5haclgxvcii3hpdvn1ah8qd0f3n8xgxxs8zryj02b8n7cz3vx";
|
|
|
|
};
|
|
|
|
|
2021-02-07 01:17:39 -08:00
|
|
|
nativeBuildInputs = [ pkg-config makeWrapper ];
|
|
|
|
buildInputs = [mono gtk-sharp-2_0 gnome2.libglade gtk2 ];
|
2015-08-15 15:05:29 -07:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin $out/lib/supertux-editor
|
|
|
|
cp *.{dll,dll.config,exe} $out/lib/supertux-editor
|
|
|
|
makeWrapper "${mono}/bin/mono" $out/bin/supertux-editor \
|
|
|
|
--add-flags "$out/lib/supertux-editor/supertux-editor.exe" \
|
2016-09-11 14:24:51 -07:00
|
|
|
--prefix MONO_GAC_PREFIX : ${gtk-sharp-2_0} \
|
2015-08-15 15:05:29 -07:00
|
|
|
--suffix LD_LIBRARY_PATH : $(echo $NIX_LDFLAGS | sed 's/ -L/:/g;s/ -rpath /:/g;s/-rpath //')
|
|
|
|
|
|
|
|
makeWrapper "${mono}/bin/mono" $out/bin/supertux-editor-debug \
|
|
|
|
--add-flags "--debug $out/lib/supertux-editor/supertux-editor.exe" \
|
2016-09-11 14:24:51 -07:00
|
|
|
--prefix MONO_GAC_PREFIX : ${gtk-sharp-2_0} \
|
2015-08-15 15:05:29 -07:00
|
|
|
--suffix LD_LIBRARY_PATH : $(echo $NIX_LDFLAGS | sed 's/ -L/:/g;s/ -rpath /:/g;s/-rpath //')
|
|
|
|
'';
|
|
|
|
|
|
|
|
# Always needed on Mono, otherwise nothing runs
|
|
|
|
dontStrip = true;
|
|
|
|
|
2021-01-10 23:54:33 -08:00
|
|
|
meta = with lib; {
|
2015-08-15 15:05:29 -07:00
|
|
|
description = "Level editor for SuperTux";
|
2020-03-31 18:11:51 -07:00
|
|
|
homepage = "https://github.com/SuperTux/supertux-editor";
|
2015-08-15 15:05:29 -07:00
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
maintainers = with maintainers; [ mathnerd314 ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|