How to upgrade an Debian Package? Part-1
This time we are going through an introduction how to upgrade an existing packages in Debian. There are basically seven steps in this process.
P.S: You can find details regarding the new terms in the footnote.
- We clone the packages repository in the salsa1 by using
gbp clone <url>
2. Note: If you are usinggit clone
3, it will createmaster
branch only, you should createupstream
andpristine-tar
branches locally by runninggit checkout upstream; git checkout pristine-tar; git checkout master
. - We now need to get the new upstream version by either using
uscan --verbose
4 or by manually downloading via git snapshots. - Import the new upstream version by
gbp import-orig --pristine-tar ../<upstream-version.orig.tar.gz>
. - Add a new section in
debian/changelog
bygbp dch -a
5 (Notdch -a
). - Build the new upgraded package by
dpkg buildpackage
6. - Fix the
lintain
7 errors. - Build the package in a clean chroot(using tools like
sbuild
8,etc.)
#Footnotes
salsa
is a collaborative development server for Debian based on the GitLab software.
gbp
is a suite to help with maintaining Debian packages in Git repositories.
git
is a Version-Control system.
uscan
is used to download the new.
dch
will add a new comment line to the Debian changelog in the current source tree.
It is a control script that can be used to construct the package automatically. Also dpkg
is the base of package management system in Debian.
lintian
dissects Debian packages and emits information about bugs and policy violations. It contains automated checks for many aspects of Debian policy as well as some checks for common errors.
sbuild
is used to test that their package builds in a minimal installation of Debian Unstable. In particular, this helps ensure that you haven't missed any build dependencies.
This is how we upgrade existing packages in Debian. In next part, we are doing to try upgrading a package and go in more depth on the process of upgrading.
:wq
for today.