Re: Can Xcode allow multiple definitions of a fn?
Re: Can Xcode allow multiple definitions of a fn?
- Subject: Re: Can Xcode allow multiple definitions of a fn?
- From: Chris Espinosa <email@hidden>
- Date: Wed, 14 Sep 2005 22:01:27 -0700
On Sep 14, 2005, at 1:08 PM, Ando Sonenblick wrote:
CW only gave warnings and I've got a deadline! Is there a way to have Xcode allow multiple definitions and just choose one (until I have more time to fix properly)?
Quoth the ld(1) man page:
<x-tad-bigger>MULTIPLY</x-tad-bigger><x-tad-bigger> </x-tad-bigger><x-tad-bigger>DEFINED</x-tad-bigger><x-tad-bigger> </x-tad-bigger><x-tad-bigger>SYMBOLS</x-tad-bigger><x-tad-bigger>
If there are multiply defined symbols in the object files being linked
into the output file being created this always results in a multiply
defined symbol error.
When the static link editor links symbols in from a dynamic library
that result in multiply defined symbols the handling depends on the
type of name space of output file being created and possibly the type
of name space of the dynamic library.
When the static link editor is creating a two-level namespace image and
a there is a multiply defined symbol from dynamic library then that
generates a multiply defined symbol warning (by default), where the
treatment of this warning can be changed with the </x-tad-bigger><x-tad-bigger>-multiply_defined</x-tad-bigger><x-tad-bigger>
flag.
When the static link editor is creating a flat namespace image and a
there is a multiply defined symbol from dynamic library, if the library
is a flat namespace image then that generates a multiply defined symbol
error. If the library is a two-level namespace image then that gener-</x-tad-bigger><x-tad-bigger>generates</x-tad-bigger><x-tad-bigger>
ates a multiply defined symbol warning (by default), where the treat-</x-tad-bigger><x-tad-bigger>treatment</x-tad-bigger><x-tad-bigger>
ment of this warning can be changed with the </x-tad-bigger><x-tad-bigger>-multiply_defined</x-tad-bigger><x-tad-bigger> flag.</x-tad-bigger>
So it looks like you want to add -multply_defined warning or -multiply-defined suppress to your Other Linker Flags.
Chris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden