[Dune] Linker flags conflict for ALUGRID and PARMETIS

Patrick Leidenberger leidenberger at ifh.ee.ethz.ch
Thu Nov 24 14:14:32 CET 2011


Hi all,

if I try to compile my code (dune-trunk, alugrid-1.23 with metis und 
parmetis) with parmetis instead of parmetis I get linking troubles:

dgfparser.cc:(.text._ZN4Dune20DuneGridFormatParser17temporaryFileNameEv[Dune::DuneGridFormatParser::temporaryFileName()]+0x34): 
warning: the use of `tmpnam' is dangerous, better use `mkstemp'
/home/patrick/extlib/parmetis/3.2.0/openmpi/1.4.2/gcc/4.5.2-8ubuntu4/libparmetis.a(kmetis.o): 
In function `ParMETIS_V3_PartKway':
kmetis.c:(.text+0xabe): undefined reference to `METIS_mCPartGraphRecursive2'

and so on.

The problem is, that in the linking command the metis path is included 
before the parmetis path. The responsible section in the automake file 
looks like this:

hades3dfeqs_LDADD = $(ALUGRID_LIBS) \
                     $(DUNEMPILIBS) \
                     $(PARMETIS_LIBS) \
                     $(LDADD)

The problem is caused by $(ALUGRID_LIBS):there is the metis path 
included before parmetis path.

Is this a bug or not? I know that I can solve my problem by reordering 
the LIBS, but I think this should be fixed, if possible, so that other 
users don't fall into the same trap like me.

Have a nice day

Patrick
-- 

-------------------------------------
Patrick Leidenberger
Phone: +41 44 63 20357
Email: leidenberger at ifh.ee.ethz.ch
Laboratory for Electromagnetic Fields
and Microwave Electronics
ETH Zuerich, Switzerland
-------------------------------------




More information about the Dune mailing list