diff options
Diffstat (limited to 'pkgs/development/libraries/science')
6 files changed, 27 insertions, 14 deletions
diff --git a/pkgs/development/libraries/science/math/coin-utils/default.nix b/pkgs/development/libraries/science/math/coin-utils/default.nix index 22aa10fc6d1..60b9de0ab33 100644 --- a/pkgs/development/libraries/science/math/coin-utils/default.nix +++ b/pkgs/development/libraries/science/math/coin-utils/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, pkg-config }: +{ lib, stdenv, fetchFromGitHub, fetchpatch }: stdenv.mkDerivation rec { version = "2.11.10"; @@ -11,6 +11,15 @@ stdenv.mkDerivation rec { hash = "sha256-Rbm45HRbRKQ6Cdup+gvKJ1xkK1HKG3irR5AIjhLer7g="; }; + patches = [ + (fetchpatch { + url = "https://github.com/coin-or/CoinUtils/commit/1700ed92c2bc1562aabe65dee3b4885bd5c87fb9.patch"; + stripLen = 1; + extraPrefix = "CoinUtils/"; + hash = "sha256-8S6XteZvoJlL+5MWiOrW7HXsdcnzpuEFTyzX9qg7OUY="; + }) + ]; + doCheck = true; meta = with lib; { diff --git a/pkgs/development/libraries/science/math/libtorch/bin.nix b/pkgs/development/libraries/science/math/libtorch/bin.nix index a47d8260714..47a6249ebdc 100644 --- a/pkgs/development/libraries/science/math/libtorch/bin.nix +++ b/pkgs/development/libraries/science/math/libtorch/bin.nix @@ -26,7 +26,7 @@ in stdenv.mkDerivation { inherit version; pname = "libtorch"; - src = fetchzip srcs."${stdenv.targetPlatform.system}-${device}" or unavailable; + src = fetchzip srcs."${stdenv.hostPlatform.system}-${device}" or unavailable; nativeBuildInputs = if stdenv.isDarwin then [ fixDarwinDylibNames ] diff --git a/pkgs/development/libraries/science/math/openblas/default.nix b/pkgs/development/libraries/science/math/openblas/default.nix index 950402315a9..3fc533e848d 100644 --- a/pkgs/development/libraries/science/math/openblas/default.nix +++ b/pkgs/development/libraries/science/math/openblas/default.nix @@ -141,7 +141,7 @@ let in stdenv.mkDerivation rec { pname = "openblas"; - version = "0.3.21"; + version = "0.3.24"; outputs = [ "out" "dev" ]; @@ -149,18 +149,9 @@ stdenv.mkDerivation rec { owner = "xianyi"; repo = "OpenBLAS"; rev = "v${version}"; - sha256 = "sha256-F6cXPqQai4kA5zrsa8E0Q7dD9zZHlwZ+B16EOGNXoXs="; + sha256 = "sha256-IuXhrZRB3o7kbnivv/6En/aAeF2F18sQw9pKs1WEJc4="; }; - patches = lib.optionals stdenv.hostPlatform.isLoongArch64 [ - # https://github.com/xianyi/OpenBLAS/pull/3626 - (fetchpatch { - name = "openblas-0.3.21-fix-loong.patch"; - url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/sci-libs/openblas/files/openblas-0.3.21-fix-loong.patch?id=37ee4c70278eb41181f69e175575b0152b941655"; - hash = "sha256-iWy11l3wEvzNV08LbhOjnSPj1SjPH8RMnb3ORz7V+gc"; - }) - ]; - postPatch = '' # cc1: error: invalid feature modifier 'sve2' in '-march=armv8.5-a+sve+sve2+bf16' substituteInPlace Makefile.arm64 --replace "+sve2+bf16" "" diff --git a/pkgs/development/libraries/science/math/suitesparse/default.nix b/pkgs/development/libraries/science/math/suitesparse/default.nix index 67dfef186e7..dd2eb9478f7 100644 --- a/pkgs/development/libraries/science/math/suitesparse/default.nix +++ b/pkgs/development/libraries/science/math/suitesparse/default.nix @@ -60,6 +60,12 @@ stdenv.mkDerivation rec { ] ; + env = lib.optionalAttrs stdenv.isDarwin { + # Ensure that there is enough space for the `fixDarwinDylibNames` hook to + # update the install names of the output dylibs. + NIX_LDFLAGS = "-headerpad_max_install_names"; + }; + buildFlags = [ # Build individual shared libraries, not demos "library" diff --git a/pkgs/development/libraries/science/math/superlu/default.nix b/pkgs/development/libraries/science/math/superlu/default.nix index 26dd00d9606..f99e86ffe47 100644 --- a/pkgs/development/libraries/science/math/superlu/default.nix +++ b/pkgs/development/libraries/science/math/superlu/default.nix @@ -21,6 +21,13 @@ stdenv.mkDerivation rec { "-DUSE_XSDK_DEFAULTS=true" ]; + env = lib.optionalAttrs stdenv.cc.isClang { + NIX_CFLAGS_COMPILE = toString [ + "-Wno-error=implicit-function-declaration" + "-Wno-error=implicit-int" + ]; + }; + patches = [ ./add-superlu-lib-as-dependency-for-the-unit-tests.patch ]; diff --git a/pkgs/development/libraries/science/math/zn_poly/default.nix b/pkgs/development/libraries/science/math/zn_poly/default.nix index 13344db9ebc..bdaf6e6284e 100644 --- a/pkgs/development/libraries/science/math/zn_poly/default.nix +++ b/pkgs/development/libraries/science/math/zn_poly/default.nix @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { # name of library file ("libzn_poly.so") libbasename = "libzn_poly"; - libext = stdenv.targetPlatform.extensions.sharedLibrary; + libext = stdenv.hostPlatform.extensions.sharedLibrary; makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ]; |