From: Manav B. <manav@u.washington.edu> - 2007-01-30 21:11:52
|
Hi, It turned out that for building a shared library on Mac OS X, all dependent libraries need to to specified on the linking. I had built petsc with parmetis support, and libmesh without it. Hence, when linking and creating the libmesh library, the dependency of petsc on parmetis was not being specified, since libmesh did not have parmetis in the external library list. I then compiled libmesh with parmetis and this solved the problem. However, there was another issue that crept up: when building parmetis in the libmesh/contrib/lib directory, I had to modify the makefile for parmetis to include -lmetis during the linking process. Without this, I was getting undefined symbol error for all the METIS symbols needed by parmetis. All this is not needed for static library building, though. Regards, Manav On Jan 29, 2007, at 4:14 PM, Manav Bhatia wrote: > Hi > I am trying to build a shared library with the following options > on a MacOS X 10.4 machine: > > CXX=mpicxx CC=mpicc ./configure --enable-shared --enable-amr -- > disable-2D-only --enable-pfem --enable-ifem --enable-second -- > enable-xdr --disable-complex --enable-reference-counting --disable- > perflog --disable-netcdf --disable-exodus --enable-mpi --enable- > petsc --disable-laspack --disable-sfc --disable-gzstreams --disable- > tecplot --disable-metis --disable-parmetis --disable-tetgen -- > disable-triangle --with-mpi=/usr/local/openmpi > > I get the following error during the link process: > > Linking /Users/manav/Documents/codes/fem/FESystem/contrib/libmesh/ > lib/i686-apple-darwin8.8.1_opt/libmesh.dylib > ld: Undefined symbols: > _ParMETIS_V3_PartKway > /usr/bin/libtool: internal link edit command failed > make: *** [/Users/manav/Documents/codes/fem/FESystem/contrib/ > libmesh/lib/i686-apple-darwin8.8.1_opt/libmesh.dylib] Error 1 > > > This is a little wierd, since I have turned off metis and parmetis > support, and it is still asking for a Parmetis symbol. I do not get > this error when I make a static library. > > Any ideas? > > Thanks, > Manav |