build backports with less work
Hi, now I think about backports.
- backports is useful, since users can get newest version without upgrade whole environment and can mostly stay with stable version
- however backports considered harmful, since sometimes it would be unmaintained
- and backports is not enough, since
- users should ask package maintainer to make backport package it's pain/hard for "average" users who need backport
- and, sometimes request would be (unfortunately) ignored...
- we have tons of packages, you know.
Sigh. Lack of human resource + not automated process makes backports harmful - then, what should we do? The answer for it, automate backporting process as much as we can. Now I'll introduce "dbackports" for you.
This is tiny tiny shell script, but it helps you to make backported package.
This is tiny tiny shell script, but it helps you to make backported package.
$ ~/bin/dbackports.shWell, you should add "X-Backports-Target: 'codename'" to its debian/control file. codename should be specify as squeeze, wheezy, etc.
no X-Backports-Target is specified in debian/control, aborting...
$ vi debian/controldbackports has some option, then you should inititialize envinroment for the pacakge.
$ ~/bin/dbackports.sh
please specify option.
Usage: dbackports [init|update|build|rollback]
$ ~/bin/dbackports.sh initOkay, now here we go.
..........
.
Ready.
$ vi debian/controlmodify debhelper version since squeeze has it until debhelper7.
$ echo 7 > debian/compat
$ ~/bin/dbackports.sh updatecreate diff for backports as below
Warning: trailing whitespace in line 6 of debian/control
dpkg-source --before-build loqui-0.5.3
fakeroot debian/rules clean
dpkg-source -b loqui-0.5.3
dpkg-genchanges -S >../loqui_0.5.3-4~bpo60+1_source.changes
dpkg-genchanges: not including original source code in upload
dpkg-source --after-build loqui-0.5.3
Now here's a backports patch in debian/backports/squeeze and its source.
Ready to build (or dbackports back).
$ cat debian/backports/squeezeit's just adjust debhelper version. Then, build it. build option invokes cowbuilder with specified distribution as X-Backports-Target (now it's squeeze).
Index: loqui-0.5.3/debian/compat
===================================================================
--- loqui-0.5.3.orig/debian/compat 2011-10-22 22:45:07.000000000 +0900
+++ loqui-0.5.3/debian/compat 2012-11-06 20:55:22.876411565 +0900
@@ -1 +1 @@
-9
+7
Index: loqui-0.5.3/debian/control
===================================================================
--- loqui-0.5.3.orig/debian/control 2012-11-06 20:54:45.612323136 +0900
+++ loqui-0.5.3/debian/control 2012-11-06 20:55:17.436398651 +0900
@@ -3,7 +3,7 @@
Priority: optional
Maintainer: Hideki Yamane <henrich@debian.org>
Uploaders: Yoichi Imai <sunnyone41@gmail.com>
-Build-Depends: debhelper (>= 9), libgtk2.0-dev (>= 2.4.0),
+Build-Depends: debhelper (>= 7), libgtk2.0-dev (>= 2.4.0),
libglib2.0-dev (>= 2.22.0), autotools-dev,
autoconf, automake, libtool
Standards-Version: 3.9.3
$ ~/bin/dbackports.sh buildThat's all. Simple - isn't it? :-) It takes only 3 mins on my box.
[sudo] password for henrich:
-> Copying COW directory
forking: rm -rf /var/cache/pbuilder/build//cow.4519
forking: cp -al /var/cache/pbuilder/squeeze.cow /var/cache/pbuilder/build//cow.451
...
real 2m59.413s
user 0m0.008s
sys 0m0.036s
Comments
Post a Comment