[Trilinos-Users] can't build Trilinos 10.2.0 with shared libraries on 10.6.3 Mac OS X

Bartlett, Roscoe A rabartl at sandia.gov
Wed Apr 28 11:01:25 MDT 2010


Jonathan,

The link problem with thyra and Stratimikos on the platform were due to a failure to include the right libraries in the CMakeLists.txt file.  For some reason, the Snow Leopard platform is the only one we have seen that catches this problem.  Somehow, things still linked on other platforms even though libraries are included correctly.  This might be the problem in this case also (a lot of development has gone one between Trilinos 10.2 and Trilinos 10.0).  Sadly, we don't have any automated testing on this specific platform to catch problems like this but if it makes you feel better, we have a backlog item to add Snow Leopard as a nightly test platform shown at:

    https://software.sandia.gov/bugzilla/show_bug.cgi?id=4617

As you can see at:

    https://software.sandia.gov/bugzilla/buglist.cgi?cmdtype=runnamed&namedcmd=Trilinos%20Framework%20Product%20Backlog

the Trilinos Framework effort has a lot of issues that need to be considered and there are only so many resources to address them.  Things like this will slip through the cracks.

I don't know if the problem you are seeing is this but my guess is that some necessary libraries are not being included in the CMakeLists.txt files like was the case with thyra and Stratimikos with Trilinos 10.0.  The developers of Tpetra and FEI most likely need access to a platform like this where they can reproduce the problem and fix it (hence, the bug 4617 above).

Cheers,

- Ross


-----------------------------------------------------------------------
Dr. Roscoe A. Bartlett
Sandia National Laboratories
Department of Optimization and Uncertainty Estimation
Trilinos Software Engineering Technologies and Integration Lead
(505) 844-5097



> -----Original Message-----
> From: trilinos-users-bounces at software.sandia.gov [mailto:trilinos-
> users-bounces at software.sandia.gov] On Behalf Of Jonathan Guyer
> Sent: Wednesday, April 28, 2010 10:36 AM
> To: Trilinos Mailing List
> Subject: [Trilinos-Users] can't build Trilinos 10.2.0 with shared
> libraries on 10.6.3 Mac OS X
> 
> I am attempting to build Trilinos 10.2.0 with PyTrilinos support on a
> MacBook running Snow Leopard 10.6.3 and with MPI built agaist Apple's
> build
> of gcc 4.2.1. I've also taken MPI out of the mix and it doesn't change
> anything.
> 
> I'm running cmake with:
> 
>     cmake \
>       -D CMAKE_INSTALL_PREFIX=$VIRTUAL_ENV \
>       -D CMAKE_OSX_ARCHITECTURES=x86_64 \
>       -D CMAKE_OSX_DEPLOYMENT_TARGET=10.6 \
>       -D Trilinos_INSTALL_INCLUDE_DIR:PATH=${VIRTUAL_ENV}/include \
>       -D Trilinos_INSTALL_LIB_DIR:PATH=${VIRTUAL_ENV}/lib \
>       -D Trilinos_INSTALL_RUNTIME_DIR:PATH=${VIRTUAL_ENV}/bin \
>       -D CMAKE_BUILD_TYPE:STRING=DEBUG \
>       -D MPI_BASE_DIR:PATH=${VIRTUAL_ENV} \
>       -D TPL_ENABLE_MPI:BOOL=ON \
>       -D Trilinos_ENABLE_ALL_PACKAGES:BOOL=ON \
>       -D Trilinos_ENABLE_ALL_OPTIONAL_PACKAGES:BOOL=ON \
>       -D BUILD_SHARED_LIBS:BOOL=ON \
>       -D Trilinos_ENABLE_PyTrilinos:BOOL=ON \
>       -D PyTrilinos_INSTALL_PREFIX:PATH=${VIRTUAL_ENV} \
>       -D SWIG_EXECUTABLE:FILEPATH=${VIRTUAL_ENV}/bin/swig \
>       -D Trilinos_ENABLE_TESTS:BOOL=ON \
>       -D DART_TESTING_TIMEOUT:STRING=600 \
>       -D Trilinos_ENABLE_Fortran:BOOL=OFF \
>       ../
> 
> but make fails with:
> 
> 
>     Linking CXX shared library libtpetratestlib.dylib
>     Undefined symbols:
>       "Teuchos::ActiveRCPNodesSetup::ActiveRCPNodesSetup()", referenced
> from:
>           __static_initialization_and_destruction_0(int, int)in
> UnitTestMissingExplicitInstantiations.cpp.o
>       "Teuchos::ActiveRCPNodesSetup::~ActiveRCPNodesSetup()",
> referenced from:
>           ___tcf_2 in UnitTestMissingExplicitInstantiations.cpp.o
>     ld: symbol(s) not found
>     collect2: ld returned 1 exit status
>     make[2]: *** [packages/tpetra/test/libtpetratestlib.dylib] Error 1
>     make[1]: ***
> [packages/tpetra/test/CMakeFiles/tpetratestlib.dir/all] Error 2
>     make: *** [all] Error 2
> 
> If I re-run cmake without '-D Trilinos_ENABLE_TESTS:BOOL=ON', then make
> fails with
> 
>     Linking CXX shared library libfei_trilinos.dylib
>     Undefined symbols:
>       "fei::Vector_core::assembleFieldData(int, int, int, int const*,
> double const*, bool, int)", referenced from:
>           fei::Vector_Impl<Epetra_MultiVector>::copyInFieldData(int,
> int, int, int const*, double const*, int)in fei_Factory_Trilinos.cpp.o
>           fei::Vector_Impl<Epetra_MultiVector>::sumInFieldData(int,
> int, int, int const*, double const*, int)in fei_Factory_Trilinos.cpp.o
> 
> fei::Vector_Impl<fei::LinearProblemManager>::copyInFieldData(int, int,
> int, int const*, double const*, int)in fei_Factory_Trilinos.cpp.o
> 
> fei::Vector_Impl<fei::LinearProblemManager>::sumInFieldData(int, int,
> int, int const*, double const*, int)in fei_Factory_Trilinos.cpp.o
> 
>       blah blah blah
> 
>     ld: symbol(s) not found
>     collect2: ld returned 1 exit status
>     make[2]: *** [packages/fei/support-Trilinos/libfei_trilinos.dylib]
> Error 1
>     make[1]: *** [packages/fei/support-
> Trilinos/CMakeFiles/fei_trilinos.dir/all] Error 2
>     make: *** [all] Error 2
> 
> (complete list of missing symbols available if you want them).
> 
> 
> 
> I see similar issues reported last October "Compiling Trilinos 10.0.1
> on
> Mac." and in December "Compiling Trilinos 10", but my undefined symbols
> are
> happening in tpetratestlib and fei_trilinos, rather than in thyra or
> stratimikos. I don't have access to either the mail archives or to bug
> 4570 to know if this has been reported and/or fixed before.
> 
> I haven't the foggiest idea what to attempt to patch the CMakeLists.txt
> files with, if that's still the solution.
> 
> 
> 
> 
> _______________________________________________
> Trilinos-Users mailing list
> Trilinos-Users at software.sandia.gov
> http://software.sandia.gov/mailman/listinfo/trilinos-users



More information about the Trilinos-Users mailing list