-*-text-*- BUILDING SWIG BINDINGS FOR SVN Step 1: Build & install the proper version of SWIG (which is currently swig 1.3.16). * Go to http://www.swig.org/, download the sourceball, unpack. * In the SWIG-X.X.X directory, run ./configure. If you plan to build the python bindings, and have a system with more than one version of python installed, you may need to pass --with-python=/path/to/correct/python/binary to the configure script. You certainly don't want to use any version of python older than 2.0. * run 'make && make install' * To verify you have the goodz installed, check that these things were created, assuming your $PREFIX was /usr/local/lib: - /usr/local/lib/swig1.3/*.i - /usr/local/lib/libswig*.so - /usr/local/bin/swig In particular, you want to make sure that libswig_py.so was built and installed, since the python bindings are the most-used ones at the moment. Step 2: Build and Install Subversion. See Subversion's own INSTALL file for details. Make sure that Subversion's ./configure script sees your installed SWIG! It tries to detect SWIG near the very end of its output. If Subversion's ./configure finds a SWIG that it's happy with, then it will build a special glue library to link svn to the swig-python bindings: libsvn_swig_py.so (as well as any other languages). SPECIFIC LANGUAGE BINDINGS * Python 1. On Unix systems, run 'make swig-py' from the top of the Subversion source tree. This will invoke SWIG on the *.i files, resulting in a collection of .c source files. It will then compile and link those .c files into Python libraries. On Windows, build the __SWIG_PYTHON__ project in Visual Studio. 2. On Unix systems, run 'make install-swig-py' (as root, typically) from the top of the Subversion source tree. This will copy your new Python libraries into the appropriate system location. Note: If you don't have access to install to python's site-packages directory, you can have the python modules install to your home directory. You can do this by running 'make install-swig-py swig_pydir=~'. Note: If you want to install to an alternate prefix (usually only if you are building packages), you can supply the prefix here. An example of doing this for building rpms looks like 'make install-swig-py DESTDIR=$RPM_BUILD_ROOT/usr'. On Windows, create two folders: \Lib\site-packages\svn \Lib\site-packages\libsvn Copy subversion\bindings\swig\python\svn\*.py into the svn folder. Copy subversion\bindings\swig\python\*.py and Release\subversion\bindings\swig\python\*.dll into the libsvn folder. Optionally, you can run the following commands to compile the python sources into bytecode: python \lib\compileall.py \Lib\site-packages\svn python \lib\compileall.py \Lib\site-packages\libsvn This can make the modules load faster for users without write access to the site-packages directory. 3. Verify that an 'svn' package has been installed correctly. You can do this by running python via 'python -c "from svn import client"'. 4. Make sure that whatever directory the bindings got installed in is in your PYTHONPATH. That directory depends on how you installed; a typical location is /usr/local/lib/svn-python/, see http://subversion.tigris.org/issues/show_bug.cgi?id=1125 for some imminent improvements to the install process. 5. Try some demo programs. From the top of your svn working copy, cd tools/examples/, and try running 'svnlook.py'. * Java The Java bindings are still under development, and have not yet reached a functional state. You can attempt to build them by running 'make swig-java' from the top level of the Subversion source tree. * Perl?