Re: linking after dependency has been modified
Re: linking after dependency has been modified
- Subject: Re: linking after dependency has been modified
- From: Stefan Werner <email@hidden>
- Date: Mon, 8 Aug 2005 01:00:43 +0200
From: Christopher Kempke <email@hidden>
Subject: Re: linking after dependency has been modified
To: email@hidden
- I turn Zerolink off - it's never worked for me with a static
library involved - it seems to prevent the static lib from being
found, even after the next step.
I have that to. Zerolink has never worked for me except for trivial
cases.
- I clean + build. It builds S, then builds A, then BOOM! Link
error because it can't find S.a, even though it just built it. (Why
isn't this automatic?)
That's something I was wondering too. When I include the static lib
in my project, shouldn't Xcode know where to find the build result?
Why do I have to tell it?
- In order to get this to work, I have to go into the build settings,
and specify the location of S.a in the "Library Search Paths", which
is a pain now in 2.1, since it's in a different place for each build
configuration. (Is there a variable for the build configuration
name? That would make it easier.)
I'm using $(CONFIGURATION). Though, I have no idea if that would work
if one of the subprojects does not have the same configuration and
falls back to 'default'.
I don't understand why all these steps are involved - a casual
reading of the documentation implies this should be happening
automatically (and certainly in Codewarrior it was "Add the static
lib project. Mark it as used by the main project. Done"). I'm
pretty sure I'm missing at least one step above- I've been fighting
to find a stable way to do this for literally weeks.
From the manual, I was under the same impression, but I never got it
to work that way myself. I'm using the same process as you are.
XCode seems to be very, very, very bad about keeping track
of what files have changed, especially in the sub-project. It will
work for a few builds, then it will stop noticing changes to files,
and I'll have to do a clean before I can get it to recognize changes
again.
Which is especially bad when debugging - often, the code I'd see in
the debugger editor is not the code that is running.
Is there an easier/more automatic way to make an project dependent on
a static lib built by another? This is an incredibly simple
configuration (application that uses an application framework in a
static library), but I spend hours and hours just trying to keep it
compiling and linking; it seems every change I make, anywhere, to
anything, causes it to throw link errors and I have to start over
again.
Those are times when you notice that Xcode is just a wrapper around
the GNU command line tools - if I hadn't had previous experience with
gcc and Make, I'd have been hopelessly lost with some problems (my
projects are filled with custom linker and compiler flags and I
always keep the detailed build results open). The "it just works"
experience that most Apple software gives you doesn't happen with
Xcode. As nice as features like smart groups or built-in design tools
probably are (neither of which I ever used), I'd be much happier if
that effort had been invested in making Xcode easier to use, more
stable and faster.
-Stefan
_______________________________________________
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