I have been trying to install Geant4 version 11.3.1 on my macbook for the past few days and keep running into errors that prevent a proper installation. I am using macOs Ventura 13.7 and Homebrew clang version 19.1.7. Futhermore I installed the prerequisites:
- command line tools
- cmake version 3.31.6
- XQuartz
- Qt5
When I run:
make -j1
The following error occurs:
Building CXX object source/CMakeFiles/G4interfaces.dir/interfaces/core/src/G4InteractorMessenger.o
And the error says:
tried including <math.h> but didn't find libc++'s <math.h> header.
This usually means that your header search paths are not configured properly. The header search paths should contain the C++ Standard Library headers before any C Standard Library, and you are probably using compiler flags that make that not be the case.
The full error can be found at:
Please let me know if you have any advice!
I redid the installation a few times but this resulted in the same error. Might it be to do with my C++ installation?