diff options
author | Loïc Minier <lool@dooz.org> | 2009-12-12 19:13:39 +0100 |
---|---|---|
committer | Loïc Minier <lool@dooz.org> | 2009-12-12 19:13:39 +0100 |
commit | 5e2bbef1410919e42f495ca25bb1606cb24c1b67 (patch) | |
tree | 6b97e30fa87231da23bbf49f98b308efd33c6e7a | |
parent | cca6306f82e354cb8b42f88f5cde2747110d602c (diff) | |
download | pbuilder-5e2bbef1410919e42f495ca25bb1606cb24c1b67.tar pbuilder-5e2bbef1410919e42f495ca25bb1606cb24c1b67.tar.gz |
Require gdebi/gdebi-core on host to resolve bdeps
Require /usr/bin/gdebi on the host to resolve build-deps using
pbuilder-satisfydepends-gdebi instead of installing it in the chroot
which resulted in a less minimal build env. Use proper package name in
Suggests.
-rw-r--r-- | debian/control | 2 | ||||
-rwxr-xr-x | pbuilder-satisfydepends-checkparams | 2 | ||||
-rw-r--r-- | pbuilder-satisfydepends-gdebi | 14 |
3 files changed, 9 insertions, 9 deletions
diff --git a/debian/control b/debian/control index a32719c..f4b5d5b 100644 --- a/debian/control +++ b/debian/control @@ -28,7 +28,7 @@ Recommends: fakeroot, sudo, devscripts Suggests: pbuilder-uml, - gdebi, + gdebi-core, cowdancer Description: personal package builder for Debian packages pbuilder constructs a chroot system, and builds a package inside the diff --git a/pbuilder-satisfydepends-checkparams b/pbuilder-satisfydepends-checkparams index 13c7674..733fdd4 100755 --- a/pbuilder-satisfydepends-checkparams +++ b/pbuilder-satisfydepends-checkparams @@ -20,6 +20,7 @@ DEBIAN_CONTROL=debian/control +CHROOT="" CHROOTEXEC="" BD_REGEXP="build-(depends|depends-indep)" BC_REGEXP="build-(conflicts|conflicts-indep)" @@ -37,6 +38,7 @@ while [ -n "$1" ]; do # --chroot option and --internal-chrootexec options and --echo options somewhat conflict with each other. --chroot) + CHROOT="$2" CHROOTEXEC="chroot $2 " if [ ${CHROOTEXEC_AFTER_INTERNAL_CHROOTEXEC} = maybe ]; then echo '--chroot specified after --internal-chrootexec' >&2 diff --git a/pbuilder-satisfydepends-gdebi b/pbuilder-satisfydepends-gdebi index de33455..88bda85 100644 --- a/pbuilder-satisfydepends-gdebi +++ b/pbuilder-satisfydepends-gdebi @@ -23,21 +23,19 @@ set -e function checkbuilddep_internal () { - local BUILD_DEP_DEB_DIR=/tmp/satisfydepends-gdebi - local BUILD_DEP_DEB_CONTROL="$BUILD_DEP_DEB_DIR/`basename "$DEBIAN_CONTROL"`" + if ! [ -x /usr/bin/gdebi ]; then + echo "You need the gdebi-core package to resolve build-deps using gdebi" + exit 1 + fi - $CHROOTEXEC apt-get -y --force-yes install gdebi-core NO_RECOMMENDS="" - if VERSION=$($CHROOTEXEC /usr/bin/gdebi --version 2>/dev/null); then + if VERSION=$(/usr/bin/gdebi --version 2>/dev/null); then if dpkg --compare-versions $VERSION ge 0.3.9; then NO_RECOMMENDS="-o APT::Install-Recommends=false" fi fi - $CHROOTEXEC mkdir -p "$BUILD_DEP_DEB_DIR" - cat "$DEBIAN_CONTROL" | $CHROOTEXEC sh -c "cat >\"$BUILD_DEP_DEB_CONTROL\"" - - INSTALL=$($CHROOTEXEC /usr/bin/gdebi --quiet --apt-line $NO_RECOMMENDS $BUILD_DEP_DEB_CONTROL) + INSTALL=$(/usr/bin/gdebi --quiet --root $CHROOT --apt-line $NO_RECOMMENDS $DEBIAN_CONTROL) $CHROOTEXEC /usr/bin/apt-get install -y --force-yes $INSTALL } |