There are many ways of creating debian packages and too many resources on the internet. Due to the dynamic nature of the packaging rules, some docs may be contradictory, so it is worth focusing on the following two authoritative sources for generic Debian packaging:
But still, those docs offer too much choice, so we wrote this ALBA Packaging Guide to describe the specific workflows and tools that have been chosen for packaging for ALBA.
If some instruction in this document contradicts what you read in a more generic document, please contact someone from CTGenSoft to check if this is a mistake on our procedures or a deliberate choice (also see the CONTRIBUTING guide)
A set of practical examples have been documented. These are intended as very specific implementation examples of the ALBA Packaging Guide workflows, and should be used together with the guide.
In this guide we will use terms such as upstream, or backport, etc that have some specific meaning in the context of packaging. See the glossary for definitions
When packaging for ALBA, you will likely be in one of the following cases :
- Get the debpack Docker
- Clone the packaging repo
- Update upstream
- Edit the Debian Files
- Build package
- Update Changelog and tag
- Push to the remote git repo
- Upload artifacts
- Test the new package installation
Workflow B - Re-packaging (backporting) an existing debian package that does not yet exist in the Alba repo
- Get the debpack Docker
- Download the debian source package
- Create the local gbp repo with
gbp import-dsc
- Create the remote git repo
- Proceed as in Workflow A-4 and next
Workflow C - Packaging a setuptools-based python code for which no alba or debian package already exist.
- Get the debpack Docker
- Get the python module upstream source and cd into it
- Generate the debian source with setuptools
- Proceed as in Workflow B-3 and next
Workflow D - Packaging non-setuptools based code (e.g. C++ code) for which no alba or debian package already exist.
- Get the debpack Docker
- Get the source tarball
- Create local packaging git repo with dh_make
- Proceed as in Workflow B-4 and next