![]() | ![]() | Building Debian Packages with tla-buildpackage | ![]() |
---|
You will need to import sources into your tla-buildpackage archive on several different occasions:
You have existing Debian packages that you would like to maintain with tla-buildpackage. In this case, you'll want to import one or more full Debian source packages with tbp-importdsc.
You want to package some previously-unpackaged software for Debian. In this case, you'll want to import an upstream tarball with tbp-importorig.
You want to update your Debian package with a new version of upstream source. This case also calls for tbp-importorig.
You want to import Debian sources from someone else (for instance, if someone NMU's a package you maintain) into your tree. tbp-importdsc can handle that.
There are two different programs that handle importing: tbp-importdsc and tbp-importorig. Both are covered in this chapter.
Importing a package is very easy. All you have to do is run tbp-importdsc with the name of a .dsc file to import:
$ tbp-importdsc ~/dpkg/rdiff-backup_0.12.3-1.dsc * tar -zxSpf "/home/jgoerzen/dpkg/rdiff-backup_0.12.3.orig.tar.gz" *** Import upstream package rdiff-backup version 0.12.3 from directory /home/jgoerzen/tree/debian/,,tbp-importorigtargz/rdiff-backup-0.12.3 ... * commited jgoerzen@complete.org--debian/configs--head--1.0--patch-1 ... Committed jgoerzen@complete.org--debian/rdiff-backup--debian--1.0--patch-1 ... * commited jgoerzen@complete.org--debian/configs--head--1.0--patch-2
In this example, I had never imported rdiff-backup before. tbp-importdsc therefore initialized the repository for me. It then added and committed the upstream version (the first commit message), committed the Debian diffs (second commit), and noted which version in the archive corresponds to 0.12.3 and 0.12.3-1 (third commit message).
I can run it again with a new version:
$ tbp-importdsc ~/dpkg/rdiff-backup_0.12.5-1.dsc * tar -zxSpf "/home/jgoerzen/dpkg/rdiff-backup_0.12.5.orig.tar.gz" *** Import upstream package rdiff-backup version 0.12.5 from directory /home/jgoerzen/tree/debian/,,tbp-importorigtargz/rdiff-backup-0.12.5 ... * commited jgoerzen@complete.org--debian/rdiff-backup--head--1.0--patch-2 ... Committed jgoerzen@complete.org--debian/rdiff-backup--debian--1.0--patch-2 ... * commited jgoerzen@complete.org--debian/configs--head--1.0--patch-4
tbp-importdsc is smart enough to know not to import an upstream version twice. For instance, if I would now load 0.12.5-2, there would be only two commits: a patch-3 on the Debian tree and a patch-5 on the configs tree.
tbp-importdsc has a few restrictions: you must always load packages in ascending order of package version. Please see tbp-importdsc(1) for more details.
While tbp-importdsc can solve many problems, sometimes you need to import just upstream sources (the Debian orig.tar.gz file). For this task, tbp-importorig exists. You will often use it if you have already loaded all the Debian versions into your archive, upstream has released a new version, and you want to package that version.
Using tbp-importorig is simple and straightforward; please refer to tbp-importorig(1) for more details.
<<< Getting Started | Common Tasks >>> |