My earlier change mistakenly expected `toString false` to produce '0'
instead of the empty string, leading to unexpected config changes.
Intended to address issue mentioned here and in following discussion:
https://github.com/NixOS/nixpkgs/pull/53972#issuecomment-459981602
Sorry, folks!
(special-case handling of bools here makes this "cleanup" a bit
less of an obvious win but hopefully still preferable overall :))
-----------
makeFlags in resulting derivation, according to this one-liner:
$ nix show-derivation -f . openblas|jq ".[].env.makeFlags"
before:
"BINARY=64 CC=cc CROSS= DYNAMIC_ARCH=1 FC=gfortran HOSTCC=cc INTERFACE64=1 NO_BINARY_MODE= NO_STATIC=1 NUM_THREADS=64 PREFIX=/1rz4g4znpzjwh1xymhjpm42vipw92pr73vdgl6xs1hycac8kf2n9 TARGET=ATHLON USE_OPENMP=1"
after:
"BINARY=64 CC=cc CROSS=0 DYNAMIC_ARCH=1 FC=gfortran HOSTCC=cc INTERFACE64=1 NO_BINARY_MODE=0 NO_STATIC=1 NUM_THREADS=64 PREFIX=/1rz4g4znpzjwh1xymhjpm42vipw92pr73vdgl6xs1hycac8kf2n9 TARGET=ATHLON USE_OPENMP=1"
Without knowing how `placeholder` works, it seems interesting if
entirely unrelated that the `PREFIX` is same for both! :). TIL.
This reverse changes made cfc4313 which broke builds on linux. Still
not sure why this broke Linux, but we can investigate it later.
“buildPackages.stdenv.cc” shouldn’t be put in nativeBuildInputs in
general. Either way, this restores hashes to before that commit.
thanks to @jethrokuan
The openblas script relies on CC=clang for succesfully compiling on
Darwin systems. This seems like bad behavior, but we get things like
https://hydra.nixos.org/build/87657058 otherwise.
Fixes#55536.
Comments on conflicts:
- llvm: d6f401e1 vs. 469ecc70 - docs for 6 and 7 say the default is
to build all targets, so we should be fine
- some pypi hashes: they were equivalent, just base16 vs. base32
* openblas: simplify a bit, fix doCheck so tests are enabled non-cross.
* doCheck should be 'true' in (at least) the non-cross case,
this looks like an inverted check that's largely benign
* doCheck will be set to 'false' in the cross case anyway,
makeDerivation does this IIRC
* targetPrefix can be used without checking, probably by design
Derivation hash does change but no "real" functionality change intended.
* openblas: nix types for config attrs (hash-preserving)
* openblas: more nix-ification, merge in cross attrs, prefer to always set
(but set appropriately for cross and non-cross cases both)
* I'm not sure what NO_BINARY_MODE does,
this change now sets explicitly false in the non-cross scenario
(previously unset unless cross).
* Drop musl NO_AFFINITY case, will be removed in upgrade shortly
* openblas: 0.3.4 -> 0.3.5
Since Intel's default openmp implementation is available in the same src
tarball, we can just include it in the package. This means that `mkl` now "just
works" without any environment variables, fragile setup-hooks, or forced
propagation.
Since the openmp implementation is only needed at runtime (and for test cases),
users can substitute a different one if they prefer by exporting it with
`LD_PRELOAD`, which is how Intel recommends handling this. If they do not do so,
`libiomp.so` lives next to `libmkl_rt.so` and thus will be in the RPATH as a
sane default.
Since this still comes from the same src tarball, we can ship it without losing
the fixed-output derivation; likewise, since Hydra is not building or caching
these, shipping these proprietary packages costs no bandwidth for the nix
community.
Suitesparse libraries would end up containing references to the build
directory. fixDarwinDylibNames appears to not fix this problem. We
manually use intall_name_tool to set the library paths correctly.