App-perlbrew
App-perlbrew copied to clipboard
Install fail on OSX 12.6.2
The relevant Configure output seems to be:
Use which C compiler? [clang]
clang: error: invalid arch name '-arch -mmacosx-version-min=12.6'
clang: error: invalid arch name '-arch try.c'
clang: error: no input files
Uh-oh, the C compiler 'clang' doesn't seem to be working.
Is there a way I can specify my arch?
I seem to be able to run Configure manually. How can I determine what perlbrew is passing to Configure?
I was running with
perlbrew install -v -j8 --noman --64int --64all --ld --switch --clang perl-5.34.1
Turns out --64all was breaking it :\
I seem to be able to run Configure manually. How can I determine what perlbrew is passing to Configure?
The answer to this was using the -v option.
The failure output is pretty bad here from Configure. The only thing I wonder is if perlbrew should have the smarts to know that --64all is fatal to clang on osx or if I should ping @tux about doing something in Configure.
See also https://stackoverflow.com/q/77161089/2173773 and https://github.com/Perl/perl5/issues/21512
--64all is fatal to clang
Can confirm that the failure does not occur if I omit '-Duse64bitall', also make runs with no errors, but then make test fails with:
$ make test
[...]
Making all in dist/threads
/Applications/Xcode.app/Contents/Developer/usr/bin/make all PERL_CORE=1 LIBPERL_A=libperl.dylib LINKTYPE=dynamic
DYLD_LIBRARY_PATH=/Users/hakonhaegland/perl/test/perl-5.14.4 ./miniperl -Ilib make_ext.pl lib/auto/threads/shared/shared.bundle MAKE=/Applications/Xcode.app/Contents/Developer/usr/bin/make LIBPERL_A=libperl.dylib LINKTYPE=dynamic
Making threads::shared (all)
Making all in dist/threads-shared
/Applications/Xcode.app/Contents/Developer/usr/bin/make all PERL_CORE=1 LIBPERL_A=libperl.dylib LINKTYPE=dynamic
cd x2p; DYLD_LIBRARY_PATH=/Users/hakonhaegland/perl/test/perl-5.14.4 /Applications/Xcode.app/Contents/Developer/usr/bin/make s2p
make[1]: `s2p' is up to date.
cd t && (rm -f perl; /bin/ln -s ../perl perl)
DYLD_LIBRARY_PATH=/Users/hakonhaegland/perl/test/perl-5.14.4 ./runtests choose
dyld[29249]: Library not loaded: /usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib
Referenced from: <116C2A3D-6FB0-309C-ADDC-1DA49649B1E5> /Users/hakonhaegland/perl/test/perl-5.14.4/perl
Reason: tried: '/usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib' (no such file), '/usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib' (no such file), '/usr/local/lib/libperl.dylib' (no such file), '/usr/lib/libperl.dylib' (no such file, not in dyld cache)
./runtests: line 51: 29249 Abort trap: 6 $PERL $TESTFILE $TEST_ARGS $TEST_FILES < /dev/tty
make: *** [test] Error 134
I notice this line:
dyld[29249]: Library not loaded: /usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib
that file does not exist on my computer, rather the file is in the current directory
$ pwd
/Users/hakonhaegland/perl/test/perl-5.14.4
$ file libperl.dylib
libperl.dylib: Mach-O 64-bit dynamically linked shared library arm64
also this file contains reference to the nonexisting file (which I guess is the reason why dyld is failing):
$ otool -L libperl.dylib
libperl.dylib:
/usr/local/lib/perl5/5.14.4/darwin-thread-multi-2level/CORE/libperl.dylib (compatibility version 5.14.0, current version 5.14.4)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1319.0.0)
Just FYI: in case this is on ARM, the issue is with the darwin hints: https://github.com/Perl/perl5/pull/22672/commits/796f85dcc918f40ac12ea01b9cdeb3d8224beaeb Perl/perl5#22672