
9 Feb
2012
9 Feb
'12
12:57 a.m.
The linker requires that libraries come after anything that depends on them. Try mpic++ ... main.cpp -lboost_mpi -lboost_serialization
Assuming you're using the GNU linker editor, you can also do this: mpic++ (...) -Wl,--start-group (list stuff to use when linking) -Wl,--end-group (...) This causes the linker to do multiple passes to satisfy dependencies so you don't have to get the order right. In Solaris, it's: -Wl,-zrescan-start (...) -Wl,-zrescan-end -Brian