default.nix (973B)
1 { 2 lib, 3 stdenv, 4 fetchurl, 5 unzip, 6 wine, 7 writers, 8 }: 9 let 10 runScript = writers.writeBash "gpxeditor" '' 11 export WINEDEBUG=warn+all 12 ${wine}/bin/wine @out@/GPX_Editor.exe 13 ''; 14 in 15 stdenv.mkDerivation (finalAttrs: { 16 pname = "gpxeditor"; 17 version = "1.8.0"; 18 19 src = fetchurl { 20 url = "mirror://sourceforge/gpxeditor/GPX%20Editor/GPX%20Editor%20${finalAttrs.version}.zip"; 21 hash = "sha256-KgVwx79kOQzXJQaQK1VRWHJHIU4yBpCH/7pFh7G4D54="; 22 }; 23 24 dontUnpack = true; 25 26 installPhase = '' 27 install -dm755 $out/bin 28 substitute ${runScript} $out/bin/gpxeditor --subst-var out 29 chmod +x $out/bin/gpxeditor 30 31 ${unzip}/bin/unzip $src -d $out 32 ''; 33 34 preferLocalBuild = true; 35 36 meta = { 37 description = "Load, modify and save your GPX files"; 38 homepage = "https://sourceforge.net/projects/gpxeditor/"; 39 license = lib.licenses.gpl2; 40 maintainers = [ lib.maintainers.sikmir ]; 41 platforms = lib.platforms.all; 42 skip.ci = true; 43 }; 44 })