3

Debian/Ubuntu question here. I routinely backport packages from more recent Ubuntu distros to older ones (LTS). I download (via dget) a Debian source, then cd into it and type debuild -b. It then says something like

dpkg-checkbuilddeps: Unmet build dependencies: dh-autoreconf gnome-pkg-tools (>= 0.7) yelp-tools gtk-doc-tools (>= 1.12) pkg-config libglib2.0-dev (>= 2.29.14) libgstreamer1.0-dev (>= 0.11.92) libgstreamer-plugins-base1.0-dev (>= 0.11.92) libxml2-dev (>= 2.6.0) libsm-dev libice-dev libgtk-3-dev (>= 3.0.0) libcanberra-dev (>= 0.1) libcanberra-gtk3-dev (>= 0.1) libnautilus-extension-dev (>= 2.91.90) libburn-dev (>= 0.4.0) libisofs-dev (>= 0.6.4) libtotem-plparser-dev (>= 2.32) libunique-dev (>= 1.0.0) libnotify-dev (>= 0.6.1) gobject-introspection (>= 0.6.3) libgirepository1.0-dev (>= 0.6.3) libappindicator3-dev (>= 0.0.7) libunity-dev (>= 5.0.0)

apt-get build-dep helps upto a certain point (but downloads dependencies for the current package, not for the one I'm backporting). I could manually install all the listed dependencies and retry the debuild to see if dpkg-checkbuilddeps succeeds, but this is costly in time (and disk space).

I guess I really I need a tool (or a script) that could check if the Build-Depends: requirements from debian/control are satisfiable with the current repositories (or if not which further packages I need to backport). Is there an easy way to achieve this?

3

There are some things that can help make the backporting easier. The first is mk-build-deps. When ran from the source directory it will create a dummy package which depends on the current package. Since this creates depends on the package you are building and not the one in your current repository, you will notice immediately if some dependencies can't be satisfied.

There is a method you can use to check if a package can be backported from sid to stable. The ircbot "judd" in #debian on irc.oftc.net and irc.freenode.net has a checkbackport command. Here is an example:

[23:53] <jordanm> checkbackport apache2
[23:53] <judd> Backporting package apache2 in sid→wheezy/i386: unsatisfiable build dependencies: Build-Depends: libaprutil1-dev (>= 1.5.0).

It would be possible to implement something similar yourself. Unfortunately, the method judd uses queries the UDD (Ultimate Debian Database), which is quite large. Judd's source code is available here if you are interested in how it is implemented.

  • mk-build-deps sounds like just what I need. – dan3 Oct 16 '13 at 17:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.