This project holds common buildystem stuff, mainly debian packaging support. It is intended to be plugged into other projects via git submodule machinery.
Your project is expected to have following directory structure. Component is anything you want to build. There can be one or more components. It is recommended that one component has name similar to project name, e.g. project vts-tools
can have component named tools
.
externals/ # all submodules of this project
externals/buildsys/ # build system parts (submodules)
externals/buildsys/common # this project as a submodule
component/ # root directory of a component named "component"
component/buildsys -> ../externals/buildsys # symlink to build system
component/Makefile -> buildsys/X/X.mk # main makefile, symlink to module's desired buildsystem
component/src/ # all sources belong here
component/debian/ # native debian packaging (optional)
Inside your project root add buildsys-common
repository (this) as a submodule into externals/buildsystem/common
.
git submodule add ../buildsys-common externals/buildsys/common
Move to your component
root under the project root and create a buildsys
symlink:
cd component
ln -s ../externals/buildsys
If a component uses buildsys-common
as desired build system symlink provided common.mk
file into component:
cd component
ln -s buildsys/common/common.mk Makefile
This core build system part adds support for debian packaging. Component can provide either proper debian/
directory or any number of directories in any of these formats: debian.CUSTOMER
, debian.RELEASE
and debian.CUSTOMER.RELEASE
where
- CUSTOMER is a name of custom build specified by DEB_CUSTOMER make variable (defaults to
internal
) - RELEASE is a name of Debian release determined by
Codename
obtained fromlsb_release -c
command output.
NB: Multiple debian.*
directories are supported by creating debian
symlink pointing to proper debian.*
directory at all debian-related targets. Therefore DEB_CUSTOMER
variable set to the same value must be used during subsequent calls to make dch
, make deb
and make dput
, e.g. make dch DEB_CUSTOMER=abc
.
Makes a debian package. Runs dpkg-buildpackage
.
Cleans after debian packaging.
Pushes latest package to remote package tree. Default configuration is set to suit Melown Technologies needs but one can change path to dput.cf
and distribution to use via make or environment variables DPUT_CONFIG
and DPUT_DISTRIBUTION
. It is recommended to export these variable in user's profile (e.g. ~/.bashrc
).
Shows latest debian package version (head of appripriate debian*/changelog
file).
Runs debchange
to edit appropriate debian*/changelog
file.
Runs debsign
to (re)sign package.