diff options
author | sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org> | 2021-08-08 20:09:38 +0200 |
---|---|---|
committer | sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org> | 2021-08-08 20:09:38 +0200 |
commit | 38b4a4364de02412795e4a452a0cfab9189d228f (patch) | |
tree | 538a2f81ef2017c25fc83ca4ba8470bae342b63f | |
parent | 52279811f541b0ac5b27379c40a401a7ef5f7c8e (diff) | |
download | nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar.gz nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar.bz2 nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar.lz nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar.xz nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.tar.zst nixpkgs-38b4a4364de02412795e4a452a0cfab9189d228f.zip |
ecl: inform ecl about libraries to link against via configure flags
All libraries that ecl will have compiled libraries and executables link against now have their own --with-<dep>-incdir and --with-<dep>-libdir flag which is perfect for our distinct lib and dev outputs. Consequently, we can get rid of the NIX_LDFLAGS-based hack in the wrapper since ecl can figure out which flags to pass on its own.
-rw-r--r-- | pkgs/development/compilers/ecl/default.nix | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/pkgs/development/compilers/ecl/default.nix b/pkgs/development/compilers/ecl/default.nix index 269beef9e7a..e891c898c47 100644 --- a/pkgs/development/compilers/ecl/default.nix +++ b/pkgs/development/compilers/ecl/default.nix @@ -45,20 +45,20 @@ stdenv.mkDerivation { configureFlags = [ (if threadSupport then "--enable-threads" else "--disable-threads") - "--with-gmp-prefix=${lib.getDev gmp}" - "--with-libffi-prefix=${lib.getDev libffi}" - ] ++ lib.optional useBoehmgc "--with-libgc-prefix=${lib.getDev boehmgc}" - ++ lib.optional (!noUnicode) "--enable-unicode"; + "--with-gmp-incdir=${lib.getDev gmp}/include" + "--with-gmp-libdir=${lib.getLib gmp}/lib" + "--with-libffi-incdir=${lib.getDev libffi}/include" + "--with-libffi-libdir=${lib.getLib libffi}/lib" + ] ++ lib.optionals useBoehmgc [ + "--with-libgc-incdir=${lib.getDev boehmgc}/include" + "--with-libgc-libdir=${lib.getLib boehmgc}/lib" + ] ++ lib.optional (!noUnicode) "--enable-unicode"; hardeningDisable = [ "format" ]; - postInstall = let - ldArgs = lib.strings.concatMapStringsSep " " - (l: ''--prefix NIX_LDFLAGS ' ' "-L${l.lib or l.out or l}/lib"'') - ([ gmp libffi ] ++ lib.optional useBoehmgc boehmgc); - in '' + postInstall = '' sed -e 's/@[-a-zA-Z_]*@//g' -i $out/bin/ecl-config - wrapProgram "$out/bin/ecl" --prefix PATH ':' "${gcc}/bin" ${ldArgs} + wrapProgram "$out/bin/ecl" --prefix PATH ':' "${gcc}/bin" ''; meta = with lib; { |