default.nix (1069B)
1 { 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 buildPerlPackage, 6 shortenPerlShebang, 7 XMLParser, 8 }: 9 10 buildPerlPackage { 11 pname = "gpx-layer"; 12 version = "0-unstable-2013-09-19"; 13 14 src = fetchFromGitHub { 15 owner = "e-n-f"; 16 repo = "gpx-layer"; 17 rev = "746b4723cf1f69fb86d45cf2d4efeaae9e711d2d"; 18 hash = "sha256-I9/ZkfrDNT0AZzcUAIShfSviP5dLvVvByJW6UrF0u2w="; 19 }; 20 21 outputs = [ "out" ]; 22 23 nativeBuildInputs = lib.optional stdenv.isDarwin shortenPerlShebang; 24 25 propagatedBuildInputs = [ XMLParser ]; 26 27 preConfigure = "touch Makefile.PL"; 28 29 installPhase = 30 '' 31 install -Dm755 parse-gpx $out/bin/datamaps-parse-gpx 32 '' 33 + lib.optionalString stdenv.isLinux '' 34 patchShebangs $out/bin/datamaps-parse-gpx 35 '' 36 + lib.optionalString stdenv.isDarwin '' 37 shortenPerlShebang $out/bin/datamaps-parse-gpx 38 ''; 39 40 meta = { 41 description = "Tools to turn GPX files into a GPS map tracing layer"; 42 homepage = "https://github.com/e-n-f/gpx-layer"; 43 license = lib.licenses.free; 44 maintainers = [ lib.maintainers.sikmir ]; 45 }; 46 }