views:

96

answers:

2

When I first started using Xcode, I didn't like the default project files location. Instead, I made a folder in my user directory instead.

Now, I think that is a mistake, since I now link to libraries in my user folder. If I share code with someone, it breaks (since my user folder isn't located on their machines).

What's the best practice for:

  1. The location to keep my project folders
  2. The location to keep 3rd party/open source libraries and frameworks

Also what is the rationale for these practices?

Thanks.

+2  A: 

Put both in a subfolder in your user directory and adjust the paths in XCode to be relative.

grahamparks
A: 

The two general techniques:

a) Set your Build Products directory (Xcode > Preferences > Building). Then all projects share that one directory, and you can refer to built libraries from other projects relative to the Build Products directory. Then your projects are independent of location, and portable.

b) Define your own Source Tree to common sources and libraries (Xcode > Preferences > Source Tree). Make your library references and search paths relative to the Source Tree. Every developer on your team can put their stuff wherever they want, and just set up the Source Tree on their system so that the projects find it.

cdespinosa
Thanks Chris. I have a build products directory and a source tree setup. Is there anything special to get "open quickly" to work for my files? And shouldn't you be busy or resting?
Corey Floyd