Re: Dumb include path/groups/folder references problem
Re: Dumb include path/groups/folder references problem
- Subject: Re: Dumb include path/groups/folder references problem
- From: Matthias Juwan <email@hidden>
- Date: Mon, 4 Oct 2004 23:18:06 +0200
Hi,
please, can any of the experts comment on this? I have a similar problem here with string.h. I solved it for now by including the standard string.h with an absolute path...
#include </usr/include/string.h>
...and my private one something like...
#include "mylib/whatever/string.h"
I did not set any extra search paths, except "../.." to be in my development root folder. I played around a while with "-I-" GCC option, but no luck so far.
Regards,
Matthias
On Oct 2, 2004, at 5:14 PM, George van den Driessche wrote:
Hi,
I'm trying to bring some code originally developed under Windows across to OSX, using XCode 1.5. There is a main target project and a couple of libraries; here's a subset:
Library A
---------
g
+-cont
+-string.h
Executable B
------------
(Depends on Library A)
main.cpp:
#include <Carbon/Carbon.h>
#include <g/cont/string.h>
...
I've set up a Source Tree path to point to Library A. I created a target for the executable and added Library A's path to the External Frameworks and Libraries group.
Now, when I try to compile main.cpp, something from within Carbon.h is trying to include <String.h> (i.e. the standard C library header) but is instead picking up g/cont/string.h. This happens regardless of whether Library A is referenced using an absolute path or the Source Tree path I set up. Is this the same problem that used to exist in CodeWarrior, where specifying an include path meant recursively specifying every subdirectory in it? If so, how does one solve it?
I tried adding folder references for Library A instead of groups, but then I find that main.cpp can't find g/cont/string.h at all.
I think that in short my question is: how can I reference Library A from Executable B in such a way that
#include <g/cont/string.h>
works, and
#include <string.h>
includes the standard library header and not g/cont/string.h?
I've searched the XCode documentation for several hours on this topic, and Google too, and I've found nothing on the subject. Maybe I should switch to Eclipse...
Many thanks,
George
_______________________________________________
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
_______________________________________________
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