Re: ZeroLink duplicate symbol warnings
Re: ZeroLink duplicate symbol warnings
- Subject: Re: ZeroLink duplicate symbol warnings
- From: Clark Cox <email@hidden>
- Date: Sun, 7 Mar 2004 18:01:01 -0500
On Mar 07, 2004, at 12:02, Erik Stein wrote:
> Hello list --
>
> I'm getting ZeroLink duplicate symbol warnings when building/running
> my app from inside XCode.
>
>> ZeroLink: warning duplicate symbol: _CardArrayPboardType
>> will use:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/MyDocument.ob
>> also in:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/MyCard.ob
>> ZeroLink: warning duplicate symbol: _CardPboardType
>> will use:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/MyDocument.ob
>> also in:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/MyCard.ob
>> ZeroLink: warning duplicate symbol: _CardArrayPboardType
>> will use:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/MyDocument.ob
>> also in:
>> /Users/erik/Developer/Builds/ControlledBook.build/Stash.build/
>> Objects-normal/ppc/CardArrayController.ob
> ...
>
> Both symbol are only defined in MyCard.h
>> NSString *CardPboardType = @"CardPboardType";
>> NSString *CardArrayPboardType = @"CardArrayPboardType";
>
> Is this an indication of a problem with my #import-dependencies and
> should I reorganize my categories or can I safely ignore this?
Change that part of the header file to:
extern NSString *const CardPboardType;
extern NSString *const CardArrayPboardType;
Then, in *only one* source file, add the following:
NSString *CardPboardType = @"CardPboardType";
NSString *CardArrayPboardType = @"CardArrayPboardType";
--
Clark S. Cox III
email@hidden
http://homepage.mac.com/clarkcox3/
http://homepage.mac.com/clarkcox3/blog/B1196589870/index.html
[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.