How to build your project on Jenkins

We've created a script named create_package that will help you build your project, and packages of it (this script is already installed on every jenkins slave created with create_buildcosy or create_imagevm). In order to use this script you have to fill the configuration file of buildeb and put it somewhere in your git repository (or whatever VCS you use). And you have to make sure that, when you run buildeb with that configuration file you've filled, it works.

Here's how the script works. It will first try to build your project on six minimal debian systems (stable (both 32bits and 64bits), unstable (32bits & 64bits) and testing (32bits & 64bits)), to make sure that your source code compiles correctly and also to make sure that you've filled the build dependencies correctly. If all builds fails, the script will terminate with an error. Otherwise, it will continue to the next step.

So, if a build has been successful on a system, it will try to build packages of your project on it. If one or more packages have been built, they're automatically uploaded on CosyVerif's repository.

The script has some options you can use if you want to modify its behaviour:

Here's an example of how to use create_package

Example

Let's say that your git repository contains two directories : foo/ and bar/. Your configuration files is named build_config.yml and is located in foo/. Your makefile is located in bar/. You should use create_package this way:
create_package -c foo/build_config.yml -d bar/
If you just want to build your project, without creating packages you should use it that way:
create_package -c foo/build_config.yml -d bar/ -b
If you just want to create packages:
create_package -c foo/build_config.yml -d bar/ -p