Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / Mac Programming / October 2006



Tip: Looking for answers? Try searching our database.

Linker woes

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
RogueWarrior - 21 Oct 2006 04:50 GMT
I hate the weird ones.  I've got two XCode 2.4 projects.  The two are
identical except that one uses source trees and the other doesn't.
(I'm preparing for SCM).  The original project compiles and links
perfectly.  The second (soure-tree version) compiled and linked a few
days ago but refuses to do so now.  I'm getting undefined symbols for
three routines in two files.  Both of these are in the target and GCC
generates the .o files.  No matter what I do I can't get the damn thing
to link.  I checked the link list file and the two files are in there.
I checked the assembly and the routines are in there.  I even examined
the .o files in Resorcerer and the routines are in there.

What the hell is going wrong?
David M. Palmer - 21 Oct 2006 17:38 GMT
> I hate the weird ones.  I've got two XCode 2.4 projects.  The two are
> identical except that one uses source trees and the other doesn't.
[quoted text clipped - 8 lines]
>
> What the hell is going wrong?

Two link errors I have had in the past few days of converting a project:

1) Libraries are searched in order, so if library A calls symbols in
library B, you have to have A and B in that order in the command line.

2) If you try to call C code from C++, you must declare it extern "C" .

Neither of those might be applicable (if you don't use libraries  and
don't use C++).

Signature

David M. Palmer  dmpalmer@email.com (formerly @clark.net, @ematic.com)

RogueWarrior - 22 Oct 2006 17:27 GMT
These are straight C files and routines as part of a larger project.
The weird thing is that I have an earlier verison of the project that
links just fine and early on in the creation of this project it worked
fine too.

> Neither of those might be applicable (if you don't use libraries  and
> don't use C++).
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.