views:

82

answers:

2

I know how to build an existing Xcode project using xcodebuild, but I also need to generate Xcode projects from maybe a Python/Shell script. Is there any document somewhere that describes the process?

A: 

One possible way is to generate a project with Xcode and recreate the file hierarchy with your script.

mouviciel
+3  A: 

From personal experience generating xcode projects by hand is a pain; I've never seen a clear format defined anywhere, besides Apple keeps changing/adding stuff to it with each new version of Xcode.

I think the easiest way would be to use cmake/qmake or scons to generate your xcode project for you. For example, using cmake for this is pretty simple: you can have your script generate cmake makefiles, then run "cmake -G xcode" on those and it will create an xcode project for you. Also, since you mentioned python you could probably look into using scons for this purpose.

ttvd
I've heard about qmake. I wonder how they are able to manage the difficulties you mention.
Plumenator
GYP ( http://code.google.com/p/gyp/ ) can also generate Xcode projects, so that's another option.
smorgan