nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

package.nix (1078B)


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