diff options
author | Philip Taron <philip.taron@gmail.com> | 2024-04-02 10:31:36 -0700 |
---|---|---|
committer | Philip Taron <philip.taron@gmail.com> | 2024-04-02 10:50:15 -0700 |
commit | 83440df1f6c29e0fcf7dfba1e9a95138d892e703 (patch) | |
tree | b32c8f70a5f975dbc6b88ed7d46e98a2cf108a6b | |
parent | 9ce47d84cddede3ee9330f63f458e60e267f939c (diff) |
auditBlasHook: remove
This was added in https://github.com/NixOS/nixpkgs/commit/d83e9c95738df2e9f912c239201f50e53e40810b, but included substitution variables `@blas@` and `@lapack@` that were never substituted. It's not used anywhere in `nixpkgs`.
-rw-r--r-- | pkgs/build-support/setup-hooks/audit-blas.sh | 37 | ||||
-rw-r--r-- | pkgs/top-level/aliases.nix | 1 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 4 |
3 files changed, 1 insertions, 41 deletions
diff --git a/pkgs/build-support/setup-hooks/audit-blas.sh b/pkgs/build-support/setup-hooks/audit-blas.sh deleted file mode 100644 index 6a40073fb2345..0000000000000 --- a/pkgs/build-support/setup-hooks/audit-blas.sh +++ /dev/null @@ -1,37 +0,0 @@ -# Ensure that we are always linking against “libblas.so.3” and -# “liblapack.so.3”. - -auditBlas() { - local dir="$prefix" - [ -e "$dir" ] || return 0 - - local i - while IFS= read -r -d $'\0' i; do - if ! isELF "$i"; then continue; fi - - if $OBJDUMP -p "$i" | grep 'NEEDED' | awk '{ print $2; }' | grep -q '\(libmkl_rt.so\|libopenblas.so.0\)'; then - echo "$i refers to a specific implementation of BLAS or LAPACK." - echo "This prevents users from switching BLAS/LAPACK implementations." - echo "Add \`blas' or \`lapack' to buildInputs instead of \`mkl' or \`openblas'." - exit 1 - fi - - (IFS=: - for dir in "$(patchelf --print-rpath "$i")"; do - if [ -f "$dir/libblas.so.3" ] || [ -f "$dir/libblas.so" ]; then - if [ "$dir" != "@blas@/lib" ]; then - echo "$dir is not allowed to contain a library named libblas.so.3" - exit 1 - fi - fi - if [ -f "$dir/liblapack.so.3" ] || [ -f "$dir/liblapack.so" ]; then - if [ "$dir" != "@lapack@/lib" ]; then - echo "$dir is not allowed to contain a library named liblapack.so.3" - exit 1 - fi - fi - done) - done < <(find "$dir" -type f -print0) -} - -fixupOutputHooks+=(auditBlas) diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 068e2a670cb97..84e256acacfc1 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -88,6 +88,7 @@ mapAliases ({ atom-beta = throw "'atom-beta' has been removed because discontinued and deprecated. Consider using 'pulsar', a maintained fork"; # Added 2023-10-01 atomEnv = throw "'atomEnv' has been removed because 'atom' is discontinued and deprecated. Consider using 'pulsar', a maintained fork"; # Added 2023-10-01 atomPackages = throw "'atomPackages' has been removed because 'atom' is discontinued and deprecated. Consider using 'pulsar', a maintained fork"; # Added 2023-10-01 + auditBlasHook = throw "'auditBlasHook' has been removed since it never worked"; # Added 2024-04-02 avldrums-lv2 = x42-avldrums; # Added 2020-03-29 awesome-4-0 = awesome; # Added 2022-05-05 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index be0057733ef2a..e450590e9b769 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -164,10 +164,6 @@ with pkgs; ### BUILD SUPPORT - auditBlasHook = makeSetupHook - { name = "auto-blas-hook"; propagatedBuildInputs = [ blas lapack ]; } - ../build-support/setup-hooks/audit-blas.sh; - autoreconfHook = callPackage ( { makeSetupHook, autoconf, automake, gettext, libtool }: makeSetupHook { |