Content-type: text/html; charset=UTF-8
This sequence can either be called step by step (./config - make - make install) or by the mconfigure script. In that case the parameters for configure and make are defined in the PAKET.conf file. The format of this file is shown in the FILES section, for the parameters of mconfigure see mconfigure(1).
./configure performs the following tasks:
Determination of version and build number. The version number can be set in a PAKET.changelog file, can be set by the -v option of mconfigure or be set by the project itself in the PAKET.prepare script. The build number is always taken from the CM system: With SVN it is the global version number, with GIT the build number is taken from the tag. On build a tag in the form project_version-build is expected. If not present a tag in the form v_version-build is searched. Version may be 0.0 if set elsewhere. In that case PAKET.changelog should contain %VERSION%-%BUILD% as verion/build.
If a PAKET.prepare file is present in the debian directory, it is called in the project directory.
If a PAKET.prebuild file is present in the debian directory, it is called in the build directory.
If directly called via make this step can be controlled by adding environment variables. The standard make file uses the following variables:
BUILD_DIR: directory where the build command is executed (default: ., typically overridden in debian/rules.pre)
DEBIAN: In that case a PAKET.cp script and a PAKET.control file are needed in the debian directory. If pre/post installation scripts are needed, these files must be also placed in the debian directory.
A standard copyright file is included. An user defined file can be used by copying it to debian/copyright in the PAKET.prepare script.
If files are present to be placed unter /etc a conffiles is creates to avoid changes made by the administrator.
If there are additional options for the dpkg-deb command (like -Zxz for xz compression) export them in the DEB_OPTS environment var.
ZIP/TGZ: In that case a PAKET.cp is needed. The files have to be copied into $1/.... All directories/files below are zipped/tgzed.
FILE: The compile_target is copied into the base dir, the build number is included into the file name. If the target_name parameter is set the artifact is renamed into that name.
If directly called via make install this step can be controlled by adding environment variables. The standard make file uses the following variables:
DEB_OPTS: additional parameters supplied to dpkg-deb (default: none)
INSTALL_DIR: directory where the application is installed (default: /, typically overridden in debian/rules.pre)
add_conf_args Additional arguments provided to ./configure.
build_replacement Corresponds to -B option of ./configure.
compile_dir Directory relative to project directory where make is called. Corresponds to -d option of ./configure.
compile_target Target provided to make. Corresponds to -e option of ./configure.
compile_type =ANY|PDF|CPP|NONE (mandatory). Corresponds to -c option of ./configure.
multibuild=n If set, the whole build run is performed n times. As example see pdf.conf in the EXAMPLE section.
make_par Additional parameters provided to make.
run This variable is set to the run number (starting by 1) in case of a multirun configuration. See pdf.conf in the EXAMPLE section.
target_name Corresponds to -n option of ./configure.
target_type Corresponds to -t option of ./configure.
projects (0.2-%BUILD%) unstable; urgency=medium * Build in svn-Umgebung -- Michael Wagner <michael@wagnertech.de> Fr 10. Aug 22:54:48 CEST 2018
%BUILD% is replaced by the current build number determined from the CM system.
If the version number is set by the -v option or determined during build (-V option) %VERSION% has to be set here.
cp ~/build/my_artefact $1/usr/bin/
The variable _DEB_HOST_ARCH can be used in the Architecture: clause. It will be replaced by the value of DEB_HOST_ARCH of the dpkg-architecture command.
These files are expected in a debian directory, placed below the projects main directory.