stk: fix underlinking in two stkclassic libraries
Created by: nschloe
Revealed by -Wl,--no-undefined
, e.g.,
cmake \
-DCMAKE_SHARED_LINKER_FLAGS="$CMAKE_SHARED_LINKER_FLAGS -Wl,--no-undefined" \
-DBUILD_SHARED_LIBS:BOOL=ON \
-DTrilinos_ENABLE_Panzer:BOOL=ON \
-DTPL_ENABLE_MPI:BOOL=ON \
-DTrilinos_ENABLE_TESTS:BOOL=ON \
-DTrilinos_ENABLE_EXPLICIT_INSTANTIATION:BOOL=OFF \
-DSEACASExodus_ENABLE_MPI:BOOL=OFF \
../../source-upstream/
[...]
Linking CXX shared library libstkclassic_util_env.so
CMakeFiles/stkclassic_util_env.dir/RuntimeMessage.cpp.o: In function `stk_classic::aggregate_messages(ompi_communicator_t*, std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >&, char const*)':
RuntimeMessage.cpp:(.text+0x4369): undefined reference to `stk_classic::parallel_machine_size(ompi_communicator_t*)'
RuntimeMessage.cpp:(.text+0x4374): undefined reference to `stk_classic::parallel_machine_rank(ompi_communicator_t*)'
CMakeFiles/stkclassic_util_env.dir/RuntimeMessage.cpp.o: In function `stk_classic::report_deferred_messages(ompi_communicator_t*)':
RuntimeMessage.cpp:(.text+0x6505): undefined reference to `stk_classic::parallel_machine_size(ompi_communicator_t*)'
RuntimeMessage.cpp:(.text+0x6511): undefined reference to `stk_classic::parallel_machine_rank(ompi_communicator_t*)'