about summary refs log tree commit diff
path: root/pkgs/development/libraries/science/math/openblas
diff options
context:
space:
mode:
authorThomas Tuegel <ttuegel@gmail.com>2016-10-20 16:37:50 -0500
committerThomas Tuegel <ttuegel@gmail.com>2016-10-22 12:57:40 -0500
commita58ec829e4a0e4a39e843b0b35f28d657a91d1c1 (patch)
tree0dce0371e89575c880b81685853243d2bde29757 /pkgs/development/libraries/science/math/openblas
parent9cd8b4e2d7846d897787963d5a2e11d3c12f30e1 (diff)
downloadnixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar.gz
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar.bz2
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar.lz
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar.xz
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.tar.zst
nixlib-a58ec829e4a0e4a39e843b0b35f28d657a91d1c1.zip
openblas: disable some hardening flags
Diffstat (limited to 'pkgs/development/libraries/science/math/openblas')
-rw-r--r--pkgs/development/libraries/science/math/openblas/default.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/pkgs/development/libraries/science/math/openblas/default.nix b/pkgs/development/libraries/science/math/openblas/default.nix
index 368cb6d60aa5..0cc79f6b44bc 100644
--- a/pkgs/development/libraries/science/math/openblas/default.nix
+++ b/pkgs/development/libraries/science/math/openblas/default.nix
@@ -34,6 +34,21 @@ stdenv.mkDerivation {
 
   inherit blas64;
 
+  # Some hardening features are disabled due to sporadic failures in
+  # OpenBLAS-based programs. The problem may not be with OpenBLAS itself, but
+  # with how these flags interact with hardening measures used downstream.
+  # In either case, OpenBLAS must only be used by trusted code--it is
+  # inherently unsuitable for security-conscious applications--so there should
+  # be no objection to disabling these hardening measures.
+  hardeningDisable = [
+    # don't modify or move the stack
+    "stackprotector" "pic"
+    # don't alter index arithmetic
+    "strictoverflow"
+    # don't interfere with dynamic target detection.
+    "relro" "bindnow"
+  ];
+
   nativeBuildInputs = optionals stdenv.isDarwin [coreutils] ++ [gfortran perl which];
 
   makeFlags =