about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libxnd/default.nix
blob: 7313b2582bea28da103a41cc2911af64ce5143bb (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
36
37
38
39
{ lib
, stdenv
, fetchFromGitHub
, libndtypes
}:

stdenv.mkDerivation {
  pname = "libxnd";
  version = "unstable-2018-11-27";

  src = fetchFromGitHub {
    owner = "plures";
    repo = "xnd";
    rev = "8a9f3bd1d01d872828b40bc9dbd0bc0184524da3";
    sha256 = "10jh2kqvhpzwy50adayh9az7z2lm16yxy4flrh99alzzbqdyls44";
  };

  buildInputs = [ libndtypes ];

  # Override linker with cc (symlink to either gcc or clang)
  # Library expects to use cc for linking
  configureFlags = [
      # Override linker with cc (symlink to either gcc or clang)
      # Library expects to use cc for linking
      "LD=${stdenv.cc.targetPrefix}cc"
      # needed for tests
      "--with-includes=${libndtypes}/include"
      "--with-libs=${libndtypes}/lib"
  ];

  doCheck = true;

  meta = {
    description = "C library for managing typed memory blocks and Python container module";
    homepage = "https://xnd.io/";
    license = lib.licenses.bsdOriginal;
    maintainers = with lib.maintainers; [ costrouc ];
  };
}