Version control software is very important to use to keep track of changes. Today I was testing out the Xcode SCM (Software Configuration Management) integrated tools with SVN today and I had a few issues.

1. Xcode is trying to use the wrong dynamic libraries for SVN, if you update your SVN version to 1.6+. Since it’s referencing the wrong libraries you will get an error similar to this one:

Error: 155021 (Unsupported working copy format) please get a
newer Subversion client

I’ve seen this type of error when I upgraded my SVN and tried to use other SCM GUI software. To fix it I googled around and found some useful information at: Blind Genius Weblog

cd /usr/lib
sudo mkdir oldSVN
sudo mv libap*-1.dylib oldSVN
sudo mv libsvn*-1.dylib oldSVN
sudo mv libap*-1.0.dylib oldSVN
sudo mv libsvn*-1.0.dylib oldSVN
$ sudo ln -s /opt/local/lib/libap*-1.0.dylib .
$ sudo ln -s /opt/local/lib/libsvn*-1.0.dylib .
$ sudo ln -s /opt/local/lib/libap*-1.dylib .
$ sudo ln -s /opt/local/lib/libsvn*-1.dylib .

Instead of removing the library files, I moved them into a new directory as backup.

2. Now Xcode can use the correct updated libraries from SVN 1.6+, so I moved on to the next task of adding an existing project to the SVN repository. The tutorial at jms1.net was helpful in refreshing my memory for the SVN commands.

Make a project in Xcode and then use Terminal and execute the commands. If you aren’t familar with SVN check out the documentation.

cd LOCAL_PROJECT_PATH
svn mkdir SVN_REPOSITORY_LOCATION/PROJECT_NAME
svn co SVN_REPOSITORY_LOCATION/PROJECT_NAME .
svn add *
svn revert --recursive build
svn ps svn:ignore build .
svn ci

The commands create a folder in your SVN repository. Next it checks out the remote repository folder into the local project folder and add all of the project files. Once the files are “added” you’ll want to remove the build directory and ignore it from your SVN repository. Lastly it’ll commit the changes and you’re project is in the repository.

3. The project is in the repository and Xcode is using the latest version of SVN. You can use the SCM tools in Xcode to manage the project.

Tagged with:
 

6 Responses to Using SCM with SVN 1.6 and Xcode 3.1.2

  1. Ferruccio says:

    Thanks for the tip. I installed SVN through MacPorts and had to make a small change to your instructions to get it to work. I used the following commands to create the necessary symlinks:

    $ sudo ln -s /opt/local/lib/libap*-1.0.dylib .
    $ sudo ln -s /opt/local/lib/libsvn*-1.0.dylib .
    $ sudo ln -s /opt/local/lib/libap*-1.dylib .
    $ sudo ln -s /opt/local/lib/libsvn*-1.dylib .

  2. Paul Solt says:

    I’m guessing that MacPorts installed it to a different directory. You could probably just have two commands:

    $ sudo ln -s /opt/local/lib/*-1.0.dylib .
    $ sudo ln -s /opt/local/lib/*-1.dylib .

    The wildcard (*) should match both libap and libsvn.

  3. Noah says:

    Thanks! Found this via Google, just got my XCode / SVN integration up and running. Your solution worked perfectly.

    Thanks again,
    -Noah

  4. @Paul Solt You are likely to have a bunch of other libraries installed too in /opt/local/lib if you are using macports, so you probably *don’t* want to use those two wildcard commands.

  5. Paul Solt says:

    @stephen You’re right. *-1.0.dylib has the potential to match too many things.

    @Ferruccio I’ve updated the post to use your commands, since they’re less likely to cause side affects.

    $ sudo ln -s /opt/local/lib/libap*-1.0.dylib .
    $ sudo ln -s /opt/local/lib/libsvn*-1.0.dylib .
    $ sudo ln -s /opt/local/lib/libap*-1.dylib .
    $ sudo ln -s /opt/local/lib/libsvn*-1.dylib .

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>