[Dune] including vtk-libraries in the dune-build system

egleiss at iup.uni-heidelberg.de egleiss at iup.uni-heidelberg.de
Wed Nov 12 15:50:19 CET 2014


>> My opts-file looks as follows:
>>
>> CONFIGURE_FLAGS="--prefix=/Users/ericgleiss/opt --disable-documentation
>> --disable-mpiruntest --enable-parallel
>> --with-alugrid=/Users/ericgleiss/opt/alugrid
>> --with-alberta=/Users/ericgleiss/opt/alberta
>> --with-ug=/Users/ericgleiss/opt/ug-install CXX=g++-mp-4.8 CC=gcc-mp-4.8
>> F77=gfortran-mp-4.8 CXXFLAGS=\"-O3  -g0 -funroll-loops -ftree-vectorize
>> -fno-strict-aliasing -Wall -Wno-deprecated-declarations
>> -I/usr/local/include/vtk-6.1/ -L/Users/ericgleiss/VTK-build/lib \"
>> CFLAGS=\"-O3 -g0 -funroll-loops -ftree-vectorize -fno-strict-aliasing
>> -Wall -Wno-deprecated-declarations\""
>> MAKE_FLAGS="all"
> [...]
>> I do not really understand, what's happening here. I suppose that the
>> libraries are not recognized correctly. If I run the example outside the
>> dune environment it works without problems. The libraries are some
>> .dylib
>> files in the folder /Users/ericgleiss/VTK-build/lib, which I include in
>> my
>> opts-file.
>> Does anyone have a clue what is going on here?
>> How can I correctly link the libraries to the dune build system?
>> Thank you beforehand.
>
> The -L... stuff should go into LIBS (or LDFLAGS, if you believe
> ./configure
> --help) but definitely not into CXXFLAGS.  You get the error during
> linking,
> and the contents of CXXFLAGS is not passed to the linker.
>
> If this does not help send the Makefile.am that is used to build the
> program.


I have added the LDFLAGS to my opts file. It looks now as follows:

CONFIGURE_FLAGS="--prefix=/Users/ericgleiss/opt --disable-documentation
--disable-mpiruntest --enable-parallel
--with-alugrid=/Users/ericgleiss/opt/alugrid
--with-alberta=/Users/ericgleiss/opt/alberta
--with-ug=/Users/ericgleiss/opt/ug-install CXX=g++-mp-4.8 CC=gcc-mp-4.8
F77=gfortran-mp-4.8 CXXFLAGS=\"-O3  -g0 -funroll-loops -ftree-vectorize
-fno-strict-aliasing -Wall -Wno-deprecated-declarations 
-I/usr/local/include/vtk-6.1/ \"  LDFLAGS=\" -L/usr/local/lib/
-L/Users/ericgleiss/VTK-build/lib/ \" 
LIBS=\"-L/Users/ericgleiss/VTK-build/lib/ -L/usr/local/lib/ \"
CFLAGS=\"-O3 -g0 -funroll-loops -ftree-vectorize -fno-strict-aliasing
-Wall -Wno-deprecated-declarations\""
MAKE_FLAGS="all"

But nothing has changed. So I am sending the Makefile.am
Thanks.
Eric



-------------- next part --------------
A non-text attachment was scrubbed...
Name: Makefile.am
Type: application/octet-stream
Size: 1417 bytes
Desc: not available
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20141112/a4483619/attachment.obj>


More information about the Dune mailing list