Building with --enable-shared=no
#8143
Labels
build-problem
Nix fails to compile or test; also improvements to build process
--enable-shared=no
#8143
Describe the bug
I'd like to build
nix
with--enable-shared=no
on my aarch64-darwin so I can link against the static libs it generates. So I override the configure flags of thenix
derivation.Expected behavior
The overrides to successfully build the library. When I build the library in the same fashion outside
nix
(that is, with./configure --enable-shared=no && make install
from withnix develop .#native-clang11StdenvPackages
), the build successfully finishes and I'm able to inspect the output binaries.However, with these overrides from within the derivation, I get a lot of libarchive missing symbols. Errors like:
I believe this is because libarchive is a shared lib not a static lib. Any advice on (1) how to build libarchive as a static lib and (2) why this builds successfully in the
nix
shell but not a purenix
context would be appreciated!nix-env --version
outputAdditional context
Priorities
The text was updated successfully, but these errors were encountered: