Hello Lorenzo,
Thank you for your email.
Looking at the errors and the fact that it used the clang compiler I would suspect that the issue is with using clang.
We document how to use gcc on macOS and I would suggest you try this first.
You can find instructions at the top of the "New user tutorial" notebook:
https://github.com/nds-org/jupyter-et/blob/master/tutorial-server/notebooks/...
in the "Prerequisites" section.
--8<--
On Mac, please first
Install Xcode from the Apple App Store. In addition agree to Xcode license and install the Xcode Command Line Tools in Terminal
sudo xcodebuild -license sudo xcode-select --install
when using MacPorts install MacPorts for your version of the Mac operating system, if you have not already installed it (https://www.macports.org/install.php). Next, please install the following packages, using the commands:
sudo port -N install pkgconfig gcc11 openmpi-gcc11 fftw-3 gsl jpeg zlib openssl zlib bash subversion ld64 # required of macOS Monterey, see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102992 sudo port -N install hdf5 +fortran +gcc11 +openmpi configure.env="GFORTRAN_UNBUFFERED_ALL=1" sudo port select mpi openmpi-gcc11-fortran sudo port select gcc mp-gcc11
when using HomeBrew install HomeBrew for your version of the Mac operating system, if you have not already installed it (https://brew.sh/). Next, please install the following packages, using the commands:
brew install fftw gcc gsl hdf5 hwloc jpeg open-mpi openssl zlib pkg-config bash subversion --8<--
Yours, Roland
Hi, I'm trying to build the EinsteinToolkit running the command:
./simfactory/bin/sim build -j2 --thornlist ../einsteintoolkit.th.
on my mac but the result, after nearly 1h, is the following:
Undefined symbols for architecture x86_64:
"_GOMP_loop_nonmonotonic_dynamic_next", referenced from:
__ZNK13CarpetInterp219fasterp_setup_gen_tINS_17fasterp_src_loc_tEE11interpolateEPK4_cGHRKSt6vectorIiSaIiEERS6_IPdSaISB_EE._omp_fn.0 in fasterp.cc.o
__ZNK13CarpetInterp219fasterp_setup_gen_tINS_22fasterp_eno2_src_loc_tEE11interpolateEPK4_cGHRKSt6vectorIiSaIiEERS6_IPdSaISB_EE._omp_fn.0 in fasterp.cc.o
__ZN10NaNChecker10CHECK_DATAIfEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
__ZN10NaNChecker10CHECK_DATAIdEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
__ZN10NaNChecker10CHECK_DATAIeEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
_SetMatrix_JFD._omp_fn.0 in FuncAndJacobian.c.o _J_times_dv._omp_fn.0 in FuncAndJacobian.c.o ..."_GOMP_loop_nonmonotonic_dynamic_start", referenced from:
__ZNK13CarpetInterp219fasterp_setup_gen_tINS_17fasterp_src_loc_tEE11interpolateEPK4_cGHRKSt6vectorIiSaIiEERS6_IPdSaISB_EE._omp_fn.0 in fasterp.cc.o
__ZNK13CarpetInterp219fasterp_setup_gen_tINS_22fasterp_eno2_src_loc_tEE11interpolateEPK4_cGHRKSt6vectorIiSaIiEERS6_IPdSaISB_EE._omp_fn.0 in fasterp.cc.o
__ZN10NaNChecker10CHECK_DATAIfEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
__ZN10NaNChecker10CHECK_DATAIdEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
__ZN10NaNChecker10CHECK_DATAIeEEvPKT_iPKdPKNS_17t_nanchecker_infoERiiiiiPKS5_PKcRK16GROUPDYNAMICDATAi._omp_fn.0 in NaNCheck.cc.o
_SetMatrix_JFD._omp_fn.0 in FuncAndJacobian.c.o _J_times_dv._omp_fn.0 in FuncAndJacobian.c.o ..."_GOMP_loop_nonmonotonic_guided_next", referenced from:
___noexcision_mod_MOD_multiply._omp_fn.0 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.0 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.1 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.2 in NoExcision_mod.F90.o"_GOMP_loop_nonmonotonic_guided_start", referenced from:
___noexcision_mod_MOD_multiply._omp_fn.0 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.0 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.1 in NoExcision_mod.F90.o ___noexcision_mod_MOD_residual._omp_fn.2 in NoExcision_mod.F90.o"_GOMP_parallel", referenced from:
_ADMDerivatives_CalcDerivatives in calc_derivs.cc.o _Baikal_zero_rhss in zero_rhss.c.o _Baikal_floor_the_lapse in floor_the_lapse.c.o _Baikal_ADM_to_BSSN in ADM_to_BSSN.c.o _Baikal_BSSN_to_ADM in BSSN_to_ADM.c.o _Baikal_BSSN_Ricci_FD_order_2 in BSSN_Ricci_FD_order_2.c.o _Baikal_BSSN_Ricci_FD_order_4 in BSSN_Ricci_FD_order_4.c.o ..."__gfortran_os_error_at", referenced from:
_ahfinder_ in AHFinder.F.o _ahfinder_dis_ in AHFinder_dis.F.o _ahfinder_int_ in AHFinder_int.F.o _linmin_ in AHFinder_pow.F.o _ahfinder_initguess_ in AHFinder_initguess.F.o _ahfinder_gau_ in AHFinder_gau.F.o ___carpet_boxtypes_MOD_splitregionsrecursive in carpet_boxtypes.F90.o ...ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[1]: *** [/Users/lorenzo/Cactus/exe/cactus_sim] Error 1
make: *** [sim] Error 2
Is there a way to make it work?
I'm using a macbook air (2017) with macOs monterey 12.3 and xcode 13.3.
the gcc version is the following:
Apple clang version 13.1.6 (clang-1316.0.21.2)
Target: x86_64-apple-darwin21.4.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
Best regards,
Lorenzo.