about summary refs log tree commit diff
path: root/proj/default.nix
blob: 96b8470786eae50dfc36d9fcdcc03d3d27c48e7b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# Recipe for building PROJ at specific snapshot
#
# SPDX-FileCopyrightText: 2007 Marc Weber
# SPDX-FileCopyrightText: 2019 Jonathan Ringer
# SPDX-License-Identifier: MIT
#
# SPDX-FileCopyrightText: 2023 Nguyễn Gia Phong
# SPDX-License-Identifier: AGPL-3.0-or-later

{ lib, stdenv, version, fetchFromGitHub, commit, hash
, autoreconfHook, binRenameHook, pkg-config, sqlite }:

stdenv.mkDerivation rec {
  name = "proj";
  inherit version;

  src = fetchFromGitHub {
    owner = "OSGeo";
    repo = "PROJ";
    rev = commit;
    inherit hash;
  };

  nativeBuildInputs = [ autoreconfHook binRenameHook pkg-config ];
  buildInputs = [ sqlite ];
  enableParallelBuilding = true;
  outputs = [ "out" "dev" ];

  meta = with lib; {
    description = "Cartographic Projections Library";
    homepage = "https://proj.org";
    license = licenses.mit;
    platforms = platforms.all;
  };
}