I tried exporting ARCHFLAGS=-arch arm64, verifying it was set w/ env then perlbrew install .... and the resulting binary was still x86_64
~ $ env | grep ARCH
ARCHFLAGS=-arch arm64
~ $ perlbrew install --notest perl-5.38.2
Installing /Users/mstratman/perl5/perlbrew/build/perl-5.38.2/perl-5.38.2 into ~/perl5/perlbrew/perls/perl-5.38.2
This could take a while. You can run the following command on another shell to track the status:
tail -f ~/perl5/perlbrew/build.perl-5.38.2.log
perl-5.38.2 is successfully installed.
~ $ file ~/perl5/perlbrew/perls/perl-5.38.2/bin/perl
/Users/mstratman/perl5/perlbrew/perls/perl-5.38.2/bin/perl: Mach-O 64-bit executable x86_64
My
perl
binaries on an M1 mac are x86_64 which is preventing me from building DBD::Pg. I believe I need an arm64 binary.I tried exporting ARCHFLAGS=-arch arm64, verifying it was set w/
env
thenperlbrew install ....
and the resulting binary was still x86_64