How do I move the location of an xcodeproj file without breaking external build target?

Posted by petFoo on Stack Overflow See other posts from Stack Overflow or by petFoo
Published on 2012-06-14T06:54:11Z Indexed on 2012/06/18 15:16 UTC
Read the original article Hit count: 196

Filed under:
|

I have an Xcode project with a directory structure like this:

MasterProjectDir/projectname.xcodeproj
MasterProjectDir/ProjectSubDir/whatever.c
MasterProjectDir/ProjectSubDir/etc.c
MasterProjectDir/ProjectSubDir/Makefile

My xcodeproj uses an external build target to point to the Makefile using these settings:

Build Tool: /usr/bin/make
Arguments: $(ACTION)
Directory: ./ProjectSubDir

For various reasons, I need to change the project directory structure to look like this:

MasterProjectDir/projectname.xcodeproj
MasterProjectDir/whatever.c
MasterProjectDir/etc.c
MasterProjectDir/Makefile

I copied the .xcodeproj file into the ProjectSubDir and the project somehow still knows where to look for the files (?!?! - this is odd because their location is set as "relative to group" and I've just moved the xcodeproj file). It won't build. I get the following error:

make: * No targets specified and no makefile found. Stop.
Command /usr/bin/make failed with exit code 2

I could use a little help on this. There must be a setting I need to change somewhere.

© Stack Overflow or respective owner

Related posts about xcode

Related posts about xcode4.3