[Dune] Linking with OS X 10.9 Mavericks
Steffen Müthing
steffen.muething at iwr.uni-heidelberg.de
Wed Jan 29 16:38:25 CET 2014
Ok, this is the linker command generated by autotools / libtool:
Making all in lib
/bin/sh ../libtool --tag=CXX --mode=link g++-mp-4.8 -std=c++11 -march=native -Wa,-q -Wall -Wall -D_REENTRANT -fvisibility-inlines-hidden -g3 -ggdb -O0 -march=native -march=native -Wa,-q -Wall -fvisibility-inlines-hidden -Wno-unknown-pragmas -o libdunegrid.la -rpath /usr/local/lib ../dune/grid/libgrid.la -lm
libtool: link: rm -fr .libs/libdunegrid.0.dylib .libs/libdunegrid.dylib .libs/libdunegrid.la .libs/libdunegrid.lai
libtool: link: g++-mp-4.8 -dynamiclib -Wl,-undefined -Wl,dynamic_lookup -o .libs/libdunegrid.0.dylib -Wl,-force_load,../dune/grid/.libs/libgrid.a -L/Users/smuething/local/packages/tbb-4.2_2_gcc-4.8-mp/build/macos_intel64_gcc_cc4.8.2_os10.9.1_preview_release -L/Users/smuething/local/packages/alugrid-1.52_gcc-4.8-mp_mpich-3.0_parmetis-4.0/lib -L/Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib -L/Users/smuething/local/packages/parmetis-4.0.3_gcc-4.8-mp_mpich-3.0/lib -L/Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib -L/Users/smuething/local/packages/psurface-1.3.1_gcc-4.8-mp/lib -L/Users/smuething/local/packages/superlu-4.3_gcc-4.8-mp/lib -L/opt/local/lib/gcc48/gcc/x86_64-apple-darwin13/4.8.2 -L/opt/local/lib/gcc48/gcc/x86_64-apple-darwin13/4.8.2/../../.. -L./src/mpl -L./src/openpa/src /Users/smuething/local/packages/alugrid-1.52_gcc-4.8-mp_mpich-3.0_parmetis-4.0/lib/libalugrid.dylib -lparmetis -lmetis /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS2.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS3.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libdevS.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libpmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libopa.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpl.dylib -lpthread /Users/smuething/tmp/dune-cmake/dune-geometry/lib/.libs/libdunegeometry.dylib /Users/smuething/tmp/dune-cmake/dune-common/lib/.libs/libdunecommon.dylib -llapack -lblas -lgfortran -lquadmath -lm -march=native -O0 -march=native -march=native -Wl,-dylib_file -Wl,/usr/local/lib/libdunecommon.0.dylib:/Users/smuething/tmp/dune-cmake/dune-common/lib/.libs/libdunecommon.dylib -install_name /usr/local/lib/libdunegrid.0.dylib -compatibility_version 1 -current_version 1.0 -Wl,-single_module
ld: warning: directory not found for option '-L./src/mpl'
ld: warning: directory not found for option '-L./src/openpa/src'
libtool: link: (cd ".libs" && rm -f "libdunegrid.dylib" && ln -s "libdunegrid.0.dylib" "libdunegrid.dylib")
libtool: link: ( cd ".libs" && rm -f "libdunegrid.la" && ln -s "../libdunegrid.la" "libdunegrid.la" )
make[2]: Nothing to be done for `all-am'.
And this is the CMake command:
cd /Users/smuething/tmp/dune-cmake/dune-grid/build-cmake/lib && /usr/local/Cellar/cmake/2.8.12.1/bin/cmake -E cmake_link_script CMakeFiles/dunegrid.dir/link.txt --verbose=1
/Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/bin/mpicxx -march=native -Wa,-q -Wall -Wall -D_REENTRANT -fvisibility-inlines-hidden -g3 -ggdb -O0 -march=native -march=native -Wa,-q -Wall -fvisibility-inlines-hidden -Wno-unknown-pragmas -std=c++11 -dynamiclib -Wl,-headerpad_max_install_names -Wl,-flat_namespace -Wl,-flat_namespace -o libdunegrid.dylib -install_name /Users/smuething/tmp/dune-cmake/dune-grid/build-cmake/lib/libdunegrid.dylib CMakeFiles/dunegrid.dir/__/dune/grid/onedgrid/onedgrid.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/onedgrid/onedgridfactory.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/onedgrid/nulliteratorfactory.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridintersections.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggrid.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridentity.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/boundaryextractor.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridindexsets.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridfactory.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridgeometry.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/uggrid/uggridhieriterator.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/alugrid/2d/intersection.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/alugrid/2d/alu2dgridfactory.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/alugrid/3d/mappings.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/alugrid/3d/topology.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/alugrid/3d/faceutility.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/dgfparser.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/dgfug.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/basic.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/boundarydom.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/boundaryseg.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/cube.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/dim.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/general.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/gridparameter.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/interval.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/periodicfacetrans.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/projection.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/simplex.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/simplexgeneration.cc.o CMakeFiles/dunegrid.dir/__/dune/grid/io/file/dgfparser/blocks/vertex.cc.o /Users/smuething/tmp/dune-cmake/dune-geometry/build-cmake/lib/libdunegeometry.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS2.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS3.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libdevS.dylib /Users/smuething/tmp/dune-cmake/dune-geometry/build-cmake/lib/libdunegeometry.dylib /Users/smuething/tmp/dune-cmake/dune-common/build-cmake/lib/libdunecommon.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS2.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libugS3.dylib /Users/smuething/local/packages/ug-trunk_gcc-4.8-mp_mpich-3.0/lib/libdevS.dylib /Users/smuething/tmp/dune-cmake/dune-geometry/build-cmake/lib/libdunegeometry.dylib /Users/smuething/tmp/dune-cmake/dune-common/build-cmake/lib/libdunecommon.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libpmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libopa.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpl.dylib /usr/lib/libpthread.dylib /Users/smuething/local/packages/alugrid-1.52_gcc-4.8-mp_mpich-3.0_parmetis-4.0/lib/libalugrid.dylib /Users/smuething/tmp/dune-cmake/dune-geometry/build-cmake/lib/libdunegeometry.dylib /Users/smuething/tmp/dune-cmake/dune-common/build-cmake/lib/libdunecommon.dylib /Users/smuething/local/packages/alugrid-1.52_gcc-4.8-mp_mpich-3.0_parmetis-4.0/lib/libalugrid.dylib /Users/smuething/tmp/dune-cmake/dune-geometry/build-cmake/lib/libdunegeometry.dylib /Users/smuething/tmp/dune-cmake/dune-common/build-cmake/lib/libdunecommon.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libpmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpich.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libopa.dylib /Users/smuething/local/packages/mpich-3.0.4_gcc-4.8-mp/lib/libmpl.dylib /usr/lib/libpthread.dylib -framework Accelerate
Undefined symbols for architecture x86_64:
"toupper(int)", referenced from:
Dune::dgf::makeupcase(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&) in dgfparser.cc.o
Dune::dgf::makeupcase(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&) in dgfug.cc.o
Dune::dgf::makeupcase(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&) in basic.cc.o
Dune::dgf::makeupcase(std::basic_string<char, std::char_traits<char>, std::allocator<char> >&) in gridparameter.cc.o
ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[2]: *** [lib/libdunegrid.dylib] Error 1
make[1]: *** [lib/CMakeFiles/dunegrid.dir/all] Error 2
make: *** [all] Error 2
Now to figure out the relevant differences…
Steffen
Am 29.01.2014 um 16:34 schrieb Steffen Müthing <steffen.muething at iwr.uni-heidelberg.de>:
> Looking at the link Christoph posted earlier, I realized that my build was setup
> with optimization (-O3), which avoids the problem as well. So I rebuilt everything
> from scratch with -O0, and now my CMake build fails with the same error as
> Benedikt’s.
>
> I’m running an -O0 build with autotools right now…
>
> Steffen
>
> Am 29.01.2014 um 16:19 schrieb Markus Blatt <markus at dr-blatt.de>:
>
>> On Wed, Jan 29, 2014 at 03:04:39PM +0100, Benedikt Oswald wrote:
>>> one more point to consider:
>>>
>>> the compilation does not run unto this problem when using the autotools based build.
>>> what could be the reason for this ?
>>
>> that is indeed interesting. Maybe libtool is very smart. Could you
>> please provide the linker lines when using autotools.
>>
>> --
>> Do you need more support with DUNE or HPC in general?
>>
>> Dr. Markus Blatt - HPC-Simulation-Software & Services http://www.dr-blatt.de
>> Hans-Bunte-Str. 8-10, 69123 Heidelberg, Germany
>> Tel.: +49 (0) 160 97590858 Fax: +49 (0)322 1108991658
>> _______________________________________________
>> Dune mailing list
>> Dune at dune-project.org
>> http://lists.dune-project.org/mailman/listinfo/dune
>
> _______________________________________________
> Dune mailing list
> Dune at dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 495 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20140129/2f0bf65e/attachment.sig>
More information about the Dune
mailing list