The PETSc library's config/install.py script checks whether
/usr/bin/install_name_tool is an existing file:
https://gitlab.com/petsc/petsc/-/blob/master/config/install.py#L368
Therefore, it is not enough to replace it with something that we expect
to be on the PATH, as this will cause the linked if statement to be
silently skipped. The consequence is that applications linked against
this version of petsc will fail at runtime on MacOS with a dynamic
loading error.
Instead, we should replace install_name_tool with the absolute path of a
binary we know will be present at build time.
Note that this should be fixed upstream as well, but this is sufficient
to fix the runtime error.
This makes packages use lapack and blas, which can wrap different
BLAS/LAPACK implementations.
treewide: cleanup from blas/lapack changes
A few issues in the original treewide:
- can’t assume blas64 is a bool
- unused commented code
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/petsc/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/saws/getSAWs.bash -h` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/saws/getSAWs.bash --help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/saws/getSAWs.bash help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscdiff -h` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscdiff --help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscdiff -h` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscdiff --help` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py -h` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py --help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py -V` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py -v` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py --version` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py version` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py -h` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py --help` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/update.py help` and found version 3.8.4
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/sendToJenkins -h` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/sendToJenkins --help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscnagupgrade.py -h` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscnagupgrade.py --help` got 0 exit code
- ran `/nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4/bin/petscnagupgrade.py help` got 0 exit code
- found 3.8.4 with grep in /nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4
- found 3.8.4 in filename of file in /nix/store/czmq31v2xa85ql17whbn05774cncbr4a-petsc-3.8.4
- directory tree listing: https://gist.github.com/da90b8c44c7ed274deb2e1a2c7de8dad
Semi-automatic update. These checks were performed:
- built on NixOS
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/saws/getSAWs.bash -h` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/saws/getSAWs.bash --help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/saws/getSAWs.bash help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py -h` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py --help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py -V` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py -v` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py --version` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py version` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py -h` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py --help` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/update.py help` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscnagupgrade.py -h` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscnagupgrade.py --help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscnagupgrade.py help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/sendToJenkins -h` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/sendToJenkins --help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/sendToJenkins -h` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/sendToJenkins --help` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscdiff -h` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscdiff --help` got 0 exit code
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscdiff -h` and found version 3.8.3
- ran `/nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3/bin/petscdiff --help` and found version 3.8.3
- found 3.8.3 with grep in /nix/store/fgr3yvhrnvfhr0czc4ygx1mnjsrv4f4i-petsc-3.8.3