Open toraritte opened 1 year ago
I spent time investigating this and haven't cracked it and don't know when I'll come back to this again, so I want to share my current findiings.
On my machine, this error occurs because the configuration script introspects perl
to get the libraries it was linked against:
perllibs=`cd $srcdir; $vi_cv_path_perl -MExtUtils::Embed -e 'ldopts' | \
sed -e '/Warning/d' -e '/Note (probably harmless)/d' \
-e 's/-bE:perl.exp//' -e 's/-lc //'`
The perl
in nixpkgs is built with libxcrypt
, so perllibs
contains -lcrypt
but it does not contain -L/path/to/libcrypt
so the test script that configure runs fails.
I am not positive what the best fix for this is upstream, though I added the following line locally for testing:
# From above, perllibs includes libraries used to link perl. This
# can include, for example, "-lcrypt". The "ldopts" subroutine in
# the ExtUtils::Embed module does not add library search paths for
# these libraries. We prepend an appropriate search path here.
perllibs="`cd $srcdir; $vi_cv_path_perl -MConfig -e 'print ($Config{libsdirs} =~ s/^ *| +/ -L/gr)'` $perllibs"
This is enough to get past that configuration failure, but the next failures are:
In file included from if_python3.c:69:
/nix/store/p2dg6c2criaslr1m0mzypqj3n75ip5pp-python3-3.7.15/include/python3.7m/Python.h:44:10: fatal error: 'crypt.h' file not found
#include <crypt.h>
^~~~~~~~~
In file included from if_perl.xs:62:
In file included from /nix/store/7rm7caxckcl5w230468m84gvmjw2cncb-perl-5.36.0/lib/perl5/5.36.0/darwin-thread-multi-2level/CORE/perl.h:4163:
In file included from /nix/store/7rm7caxckcl5w230468m84gvmjw2cncb-perl-5.36.0/lib/perl5/5.36.0/darwin-thread-multi-2level/CORE/op.h:679:
/nix/store/7rm7caxckcl5w230468m84gvmjw2cncb-perl-5.36.0/lib/perl5/5.36.0/darwin-thread-multi-2level/CORE/reentr.h:124:16: fatal error: 'crypt.h' file not found
# include <crypt.h>
^~~~~~~~~
So crypt.h
(from libxcrypt
) is needed, but I'm not sure what the best way to add this is, and why upstream does not run into this issue.
I hope that this helps whoever picks this up next (maybe it'll be future me).
FWIW i ran into this also on Catalina last year, and basically got to the exact same spot & conclusion with debugging as @tjni did, so it's not Ventura-specific at all.
I just submitted https://github.com/NixOS/nixpkgs/pull/260094 which should fix this.
Describe the bug
Unable to "install" macvim. Found issue macvim fails to install #73514, but it didn't help (or I didn't understand it to make it work).
Metadata
Please run `and paste the result.
Steps To Reproduce
(Ran
nix log /nix/store/d8554mkbwy36a8mkdmvapx2vgmrli9jr-macvim-8.2.3455.drv
as recommended in the end, but it yielded the same output as the one below.)