git.iko.soy/typeable/nixpkgs
on master help sign in
libxnd, pythonPackages.xnd: unstable-2018-11-27 -> unstable-2019-08-01

this is the most recent commit to upstream's master at time of writing includes fixes of python package for darwin

commitdcd6847ddb75553129e666ee6f3f9763d1d18b4d authorRobert Scott <code@humanleg.org.uk> dateSat 12 Sep 2020, 01:20 (6 years ago) parent044533c
2 files changed+24−5
pkgs/development/libraries/libxnd/default.nix+12−4 pkgs/development/python-modules/xnd/default.nix+12−1
pkgs/development/libraries/libxnd/default.nix+12−4
@@ -6,13 +6,13 @@
66
77stdenv.mkDerivation {
88 pname = "libxnd";
9− version = "unstable-2018-11-27";
9+ version = "unstable-2019-08-01";
1010
1111 src = fetchFromGitHub {
12− owner = "plures";
12+ owner = "xnd-project";
1313 repo = "xnd";
14− rev = "8a9f3bd1d01d872828b40bc9dbd0bc0184524da3";
15− sha256 = "10jh2kqvhpzwy50adayh9az7z2lm16yxy4flrh99alzzbqdyls44";
14+ rev = "6f305cd40d90b4f3fc2fe51ae144b433d186a6cc";
15+ sha256 = "1n31d64qwlc7m3qkzbafhp0dgrvgvkdx89ykj63kll7r1n3yk59y";
1616 };
1717
1818 buildInputs = [ libndtypes ];
@@ -28,6 +28,14 @@ stdenv.mkDerivation {
2828 "--with-libs=${libndtypes}/lib"
2929 ];
3030
31+ # other packages which depend on libxnd seem to expect overflow.h, but
32+ # it doesn't seem to be included in the installed headers. for now this
33+ # works, but the generic name of the header could produce problems
34+ # with collisions down the line.
35+ postInstall = ''
36+ cp libxnd/overflow.h $out/include/overflow.h
37+ '';
38+
3139 doCheck = true;
3240
3341 meta = {
pkgs/development/python-modules/xnd/default.nix+12−1
@@ -1,4 +1,6 @@
1−{ buildPythonPackage
1+{ stdenv
2+, buildPythonPackage
3+, python
24, ndtypes
35, libndtypes
46, libxnd
@@ -25,5 +27,14 @@ buildPythonPackage {
2527 postInstall = ''
2628 mkdir $out/include
2729 cp python/xnd/*.h $out/include
30+ '' + stdenv.lib.optionalString stdenv.isDarwin ''
31+ install_name_tool -add_rpath ${libxnd}/lib $out/${python.sitePackages}/xnd/_xnd.*.so
32+ '';
33+
34+ checkPhase = ''
35+ pushd python
36+ mv xnd _xnd
37+ python test_xnd.py
38+ popd
2839 '';
2940}