Skip to Content.
Sympa Menu

charm - Re: [charm] [ppl] Multiple definition problem

charm AT lists.cs.illinois.edu

Subject: Charm++ parallel programming system

List archive

Re: [charm] [ppl] Multiple definition problem


Chronological Thread 
  • From: Phil Miller <mille121 AT illinois.edu>
  • To: Laércio Lima Pilla <llpilla AT inf.ufrgs.br>
  • Cc: charm AT cs.uiuc.edu
  • Subject: Re: [charm] [ppl] Multiple definition problem
  • Date: Wed, 21 Mar 2012 13:36:17 -0500
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/charm>
  • List-id: CHARM parallel programming system <charm.cs.uiuc.edu>

On Mon, Mar 12, 2012 at 10:21, Laércio Lima Pilla
<llpilla AT inf.ufrgs.br>
wrote:
> I am trying to add an external library to Charm++ that is used by multiple
> load balancers. I have no problems when compiling Charm, but when I try to
> compile an application with common lbs, I have problems with multiple
> definitions of variables that come from the original library. Any ideas
> about how to solve this? Compiling the application with
> --allow-multiple-definition does not help, as g++ says it is an unrecognized
> option.

Hi Laércio,

Have you tried linking the external library as a shared object instead
of static? That way, the runtime loader should only try to bring it in
once.

You may be able to achieve the same result with static linking if you
manually incorporate that library archive once at link time, rather
than it getting repeated for each LB.

Phil





Archive powered by MHonArc 2.6.16.

Top of Page