mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-23 06:03:40 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
48 lines
1.5 KiB
Nix
48 lines
1.5 KiB
Nix
{ lib, stdenv, fetchurl, fetchpatch, perl, zlib, bzip2 }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "routino";
|
|
version = "3.4.1";
|
|
|
|
src = fetchurl {
|
|
url = "https://routino.org/download/routino-${version}.tgz";
|
|
hash = "sha256-C6qNKljRdV0ProbgSxfrZLgZH+Pl8kcpKmTb83GLhSs=";
|
|
};
|
|
|
|
patchFlags = [ "-p0" ];
|
|
patches = lib.optionals stdenv.hostPlatform.isDarwin [
|
|
(fetchpatch {
|
|
url = "https://raw.githubusercontent.com/macports/macports-ports/18fd229516a46e7272003acbe555735b2a902db7/gis/routino/files/patch-Makefile_conf.diff";
|
|
sha256 = "1b7hpa4sizansnwwxq1c031nxwdwh71pg08jl9z9apiab8pjsn53";
|
|
})
|
|
(fetchpatch {
|
|
url = "https://raw.githubusercontent.com/macports/macports-ports/18fd229516a46e7272003acbe555735b2a902db7/gis/routino/files/patch-src_Makefile_dylib_extension.diff";
|
|
sha256 = "1kigxcfr7977baxdsfvrw6q453cpqlzqakhj7av2agxkcvwyilpv";
|
|
})
|
|
];
|
|
|
|
postPatch = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
substituteInPlace Makefile.conf \
|
|
--subst-var-by PREFIX $out
|
|
'';
|
|
|
|
nativeBuildInputs = [ perl ];
|
|
|
|
buildInputs = [ zlib bzip2 ];
|
|
|
|
outputs = [ "out" "doc" ];
|
|
|
|
CLANG = lib.optionalString stdenv.cc.isClang "1";
|
|
|
|
makeFlags = [ "prefix=$(out)" ];
|
|
|
|
meta = with lib; {
|
|
homepage = "http://www.routino.org/";
|
|
changelog = "http://routino.org/software/NEWS.txt";
|
|
description = "OpenStreetMap Routing Software";
|
|
license = licenses.agpl3Plus;
|
|
maintainers = with maintainers; [ dotlambda ];
|
|
platforms = with platforms; linux ++ darwin;
|
|
};
|
|
}
|