Hey everyone!
I usually don't program C++, so I'm kind of new to this. But the newest collaboration project contains some C++ code, which fails to compile and which I would very much like to test on my Mac.
Because of the lack of a preinstalled MPI on Lion, I mostly use the compilers from Macports. I have XCode 4.2.1 installed (because at the time, 4.3 didn't work with Macports), and for C++ I have installed the following ports:
dyld-headers
gcc44
glib2
openmpi
The compiler (/opt/local/mpiCC) works fine and produces .o files, but the linker fails to find any of the used libraries, the most clear example of error messages would probably be:
Any ideas? I know that it used to work more or less out of the box on my old laptop, which still had some leftovers from older XCode versions, but it refuses to work on my new one... maybe I'm missing something really obvious?
I usually don't program C++, so I'm kind of new to this. But the newest collaboration project contains some C++ code, which fails to compile and which I would very much like to test on my Mac.
Because of the lack of a preinstalled MPI on Lion, I mostly use the compilers from Macports. I have XCode 4.2.1 installed (because at the time, 4.3 didn't work with Macports), and for C++ I have installed the following ports:
dyld-headers
gcc44
glib2
openmpi
The compiler (/opt/local/mpiCC) works fine and produces .o files, but the linker fails to find any of the used libraries, the most clear example of error messages would probably be:
Code:
mpiCC -dynamic -o <name> <names>.o ../../src/<names>.a -lz
Undefined symbols for architecture x86_64:
"std::cout", referenced from:
...
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Any ideas? I know that it used to work more or less out of the box on my old laptop, which still had some leftovers from older XCode versions, but it refuses to work on my new one... maybe I'm missing something really obvious?