lowderchris/fluxon-mhd

macOS Mojave installation

Closed this issue · 1 comments

After a fresh installation of macOS Mojave (10.14), issues were encountered when compiling the fluxon-mhd code:

ld: library not found for -lgcc_s.10.4

I believe the root of the issue is that as of 10.14, some XCode command line tools have moved from /usr/include/ to within the XCode directory of /Library/Developer/CommandLineTools/Packages/.

The solution:

export MACOSX_DEPLOYMENT_TARGET=10.14

By specifying this environmental variable before making everything, this should point compilers in the right direction.

Note that because of my use of a bundled version of perl and PDL, this required some manual editing to the file /Applications/PDL/lib/perl5/5.22.1/darwin-2level/Config_heavy.pl to ensure this variable wasn't overwritten...