Build Tool

Since i started to use git i can't use kdesvn-build anymore. That's sad but a price i was willing to pay to get rid of subversion locally. So i started to hack on some kdesvn-build inspired tool that is able to work with git. This is the homepage for this tool.

General Features

  • Supported version control systems: GIT-SVN, SVN. It should be easy to add others.
  • Supported build tools: qmake, cmake, autoconf and some obscure ones (kde's l10n repo, qt's). It should be easy to add others.
  • Support for ctags.
  • Interactive command line
  • kdesvn-build like command line parameters
  • Support for inplace builds.
  • Support for configurations. A configuration is a list of modules and is used to build related modules at once.
  • Support for moe than one config file. The one to use is extracted from the command name. (Symlinks!)

GIT-SVN Features

  • Basic support for svn:externals. They have to be configured manually.

Planned Features

  • Automatically detect the build system. Currently it has to specified in the configuration
  • Automatically extract the target for an svn:external.
  • Fill a database with build results and provide commands to present the information
  • Start an quickfix editor in case of an error and allow fixing the bug.
  • Start an quickfix editor for an logfile
  • ????

Quickstart

You can grab it with from gitorious and install it the typical python way. python ./setup.py install # to install it as usual or python setup.py develop # to install it inplace.

The tool is installed and configured. Now it's time to use it. There are two different ways to run it. If you start it without arguments you will get an prompt. If called with arguments they are interpreted as one command and executed.

Stat the program. It will complain about a missing configuration file. Follow the message and have a look around.

Start it without arguments and type help. You will get the list of available commands. Type help update. This is the kdesvn-build like command. Other interesting commands are:

fetch
Just fetch the latest changes from the remote repository. The change are not applied to the local checkout
rebase
Fetches the latest changes and applies them to the local checkout.
configure
Reconfigure the build
make
execute make
install
make install
log
fetches and show the differences between the local checkout and the remote repository. I'm searching for a better naming for this command

The other commands are from pythons cmd2 module. They allow you to write, save, edit and execute scripts or call shell commands.

All commands work on the module from the configuration:default section or on the modules specified as arguments. If in doubt add the following two options '-vv --dry-run'. It increases the verbosity and ensures nothing is done.

The script only works if there are no local uncommited changes in the git repository. I would suggest to not work with them anyways. Clone theme locally to do changes. Or tell me about better alternatives.

More that one build configuration

The tool is able to switch the used configuration file on the fly. Go to some directory that is in your path - for example $HOME/bin here and create a link called kde4svn-build to the build-tool executable. Execute your new command. Voila.

Btw. I have no idea if the script works under windows. It could. I would like to have some feedback.

Mike