MathCancer / PhysiCell

PhysiCell: Scientist end users should use latest release! Developers please fork the development branch and submit PRs to the dev branch. Thanks!
http://PhysiCell.org
142 stars 95 forks source link

Compiling PhysiCell in a MacBook Pro with M2 #169

Open mixcoha opened 1 year ago

mixcoha commented 1 year ago

I have been unable to compile PhysiCell on my MacBookPro After make ANY-PROJECT > make, I obtain this error:

ld: symbol(s) not found for architecture arm64 clang-16: error: linker command failed with exit code 1 (use -v to see invocation) make: *** [all] Error 1

I have installed all the required programs. I've tried with several flags, and PhysiCell can be compiled.: clang-16 -march=native -O3 -fomit-frame-pointer -fopenmp -m64 -std=c++11 -v -o worm BioFVM_vector.o BioFVM_mesh.o BioFVM_microenvironment.o BioFVM_solvers.o BioFVM_matlab.o BioFVM_utilities.o BioFVM_basic_agent.o BioFVM_MultiCellDS.o BioFVM_agent_container.o pugixml.o PhysiCell_phenotype.o PhysiCell_cell_container.o PhysiCell_standard_models.o PhysiCell_cell.o PhysiCell_custom.o PhysiCell_utilities.o PhysiCell_constants.o PhysiCell_basic_signaling.o PhysiCell_signal_behavior.o PhysiCell_rules.o PhysiCell_SVG.o PhysiCell_pathology.o PhysiCell_MultiCellDS.o PhysiCell_various_outputs.o PhysiCell_pugixml.o PhysiCell_settings.o PhysiCell_geometry.o custom.o main.cpp

Do you know how I can fix this issue?

rheiland commented 1 year ago

It appears you are trying to use the clang compiler which unfortunately does not support OpenMP (which PhysiCell uses). Please see the latest setup guide for MacOS for installing/using the g++ compiler via brew: https://github.com/physicell-training/ws2023/blob/main/setup/PhysiCell_ws2023_macOS_setup.pdf