[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

pbuilder and not-unstable



Hi,

I'm trying to convert my building procedure(s) to using
pbuilder/cowbuilder to make eg. backporting and/or creating packages
for a different release, or different build requirements, feasible
(have tried VMs first, but that didn't work out, either). I also want
to use git-buildpackage.

Unfortunately, while it works for unstable, for Squeeze,
"it does not work":


After quite some effort, I have been able to create a tarball for
Squeeze, using this command:


$ sudo pbuilder --create --configfile ~toni/.pbuilder/.pbuilderrc-squeeze --basetgz /var/cache/pbuilder/base-squeeze.tgz

But trying to use this tarball to build a package fails:

$ pwd
~/mnt/deb/roundup/roundup-pkg.git/roundup-1.4.18
$ ls
./   2to3-done.txt  COPYING.txt  demo.py     doc/        .git/       locale/   MANIFEST.in  PKG-INFO    roundup/      scripts/  share/  tools/
../  CHANGES.txt    debian/      detectors/  frontends/  .gitignore  MANIFEST  .pc/         README.txt  run_tests.py  setup.py  test/
$ sudo pbuilder --debuild   --configfile ~/.pbuilder/.pbuilderrc-squeeze   --basetgz /var/cache/pbuilder/base-squeeze.tgz
W: /root/.pbuilderrc does not exist
I: Building the build Environment
I: extracting base tarball [/var/cache/pbuilder/base-squeeze.tgz]
I: creating local configuration
I: copying local configuration
I: mounting /proc filesystem
I: mounting /dev/pts filesystem
I: Mounting /var/cache/pbuilder/ccache
I: policy-rc.d already exists
I: Obtaining the cached apt archive contents
Reading package lists...
Building dependency tree...
Reading state information...
passwd is already the newest version.
The following extra packages will be installed:
  debootstrap wget
Suggested packages:
  pbuilder-uml gdebi-core cowdancer
Recommended packages:
  fakeroot sudo devscripts
The following NEW packages will be installed:
  debootstrap pbuilder wget
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/1169 kB of archives.
After this operation, 3850 kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously deselected package wget.
(Reading database ... 14420 files and directories currently installed.)
Unpacking wget (from .../wget_1.12-2.1_i386.deb) ...
Selecting previously deselected package debootstrap.
Unpacking debootstrap (from .../debootstrap_1.0.26+squeeze1_all.deb) ...
Selecting previously deselected package pbuilder.
Unpacking pbuilder (from .../pbuilder_0.199+nmu1_all.deb) ...
Setting up wget (1.12-2.1) ...
Setting up debootstrap (1.0.26+squeeze1) ...
Setting up pbuilder (0.199+nmu1) ...
I: Copying back the cached apt archive contents
I: unmounting /var/cache/pbuilder/ccache filesystem
I: unmounting dev/pts filesystem
I: unmounting proc filesystem
I: cleaning the build env 
I: cleaning up the directory /var/cache/pbuilder/build//14426
I: removing directory /var/cache/pbuilder/build//14426 and its subdirectories
$ 



Alternative approach:


$ sudo pdebuild   --configfile ~/.pbuilder/.pbuilderrc-squeeze --pbuilder cowbuilder
W: /root/.pbuilderrc does not exist
I: using cowbuilder as pbuilder
dpkg-buildpackage: warning: using a gain-root-command while being root
dpkg-buildpackage: export CFLAGS from dpkg-buildflags (origin: vendor): -g -O2
dpkg-buildpackage: export CPPFLAGS from dpkg-buildflags (origin: vendor): 
dpkg-buildpackage: export CXXFLAGS from dpkg-buildflags (origin: vendor): -g -O2
dpkg-buildpackage: export FFLAGS from dpkg-buildflags (origin: vendor): -g -O2
dpkg-buildpackage: export LDFLAGS from dpkg-buildflags (origin: vendor): 
dpkg-buildpackage: source package roundup
dpkg-buildpackage: source version 1.4.18-1~bpo60+1
dpkg-buildpackage: source changed by Toni Mueller <toni@debian.org>
 dpkg-source -i --before-build roundup-1.4.18
dpkg-source: warning: patches have not been applied, applying them now (use --no-preparation to override)
dpkg-source: info: applying 01_separate_configuration.patch
dpkg-source: info: applying 05_roundup_server_umask.patch
dpkg-source: info: applying 08_update_manpages.patch
dpkg-source: info: applying 09_german_translation.patch
dpkg-source: info: applying 11_add-old-detector-sampes.patch
dpkg-source: info: applying history-user-escape.patch
dpkg-source: info: applying no-integrated-jquery.patch
dpkg-source: info: applying fix-email-representation.patch
 fakeroot debian/rules clean
pyversions: missing X(S)-Python-Version in control file, fall back to debian/pyversions
test -x debian/rules
dh_testroot
rmdir debian/roundup
rmdir: failed to remove `debian/roundup': No such file or directory
make: [cleanbuilddir] Error 1 (ignored)
dh_clean 
        rm -f debian/roundup.substvars
        rm -f debian/roundup.*.debhelper
        rm -f debian/roundup.debhelper.log
        rm -rf debian/roundup/
        rm -f debian/files
        find .  \( \( -type f -a \
                \( -name '#*#' -o -name '.*~' -o -name '*~' -o -name DEADJOE \
                 -o -name '*.orig' -o -name '*.rej' -o -name '*.bak' \
                 -o -name '.*.orig' -o -name .*.rej -o -name '.SUMS' \
                 -o -name TAGS -o \( -path '*/.deps/*' -a -name '*.P' \) \
                \) -exec rm -f {} \; \) -o \
                \( -type d -a -name autom4te.cache -prune -exec rm -rf {} \; \) \)
        rm -f *-stamp
cd /home/toni/mnt/deb/roundup/roundup-pkg.git/roundup-1.4.18 && python setup.py clean -a
running clean
'build/lib.linux-i686-2.6' does not exist -- can't clean it
'build/bdist.linux-i686' does not exist -- can't clean it
'build/scripts-2.6' does not exist -- can't clean it
rm -rf debian/python-module-stampdir
find . -name '*.pyc' -exec rm '{}' ';'
find . -prune -name '*.egg-info' -exec rm -rf '{}' ';'
rm -fr build home
 dpkg-source -i -b roundup-1.4.18
dpkg-source: info: using source format `3.0 (quilt)'
dpkg-source: info: building roundup using existing ./roundup_1.4.18.orig.tar.gz
dpkg-source: info: building roundup in roundup_1.4.18-1~bpo60+1.debian.tar.gz
dpkg-source: info: building roundup in roundup_1.4.18-1~bpo60+1.dsc
 dpkg-genchanges -S >../roundup_1.4.18-1~bpo60+1_source.changes
dpkg-genchanges: not including original source code in upload
 dpkg-source -i --after-build roundup-1.4.18
dpkg-buildpackage: binary and diff upload (original source NOT included)
 -> Copying COW directory
  forking: rm -rf /var/cache/pbuilder/build//cow.18473 
  forking: cp -al /var/cache/pbuilder/base-squeeze.cow /var/cache/pbuilder/build//cow.18473 
I: unlink for ilistfile /var/cache/pbuilder/build//cow.18473/.ilist failed, it didn't exist?
  forking: chroot /var/cache/pbuilder/build//cow.18473 cowdancer-ilistcreate /.ilist find . -xdev -path ./home -prune -o \( \( -type l -o -type f \) -a -links +1 -print0 \) | xargs -0 stat --format '%d %i ' 
 -> Invoking pbuilder
  forking: pbuilder build --configfile /home/toni/.pbuilder/.pbuilderrc-squeeze --debbuildopts  --debbuildopts -i -us -uc --buildplace /var/cache/pbuilder/build//cow.18473 --buildresult /var/cache/pbuilder/result/ --debbuildopts -i -us -uc --no-targz --internal-chrootexec chroot /var/cache/pbuilder/build//cow.18473 cow-shell /home/toni/mnt/deb/roundup/roundup-pkg.git/roundup_1.4.18-1~bpo60+1.dsc 
W: /root/.pbuilderrc does not exist
I: Running in no-targz mode
I: using fakeroot in build.
I: Current time: Tue Jun 28 11:51:51 CEST 2011
I: pbuilder-time-stamp: 1309254711
I: copying local configuration
I: mounting /proc filesystem
I: mounting /dev/pts filesystem
I: Mounting /var/cache/pbuilder/ccache
I: policy-rc.d already exists
I: Obtaining the cached apt archive contents
I: Setting up ccache
I: Installing the build-deps
 -> Attempting to satisfy build-dependencies
 -> Creating pbuilder-satisfydepends-dummy package
Package: pbuilder-satisfydepends-dummy
Version: 0.invalid.0
Architecture: i386
Maintainer: Debian Pbuilder Team <pbuilder-maint@lists.alioth.debian.org>
Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder
 This package was created automatically by pbuilder to satisfy the
 build-dependencies of the package being currently built.
Depends: python, debhelper (>= 7.4), python-support, cdbs
dpkg-deb: building package `pbuilder-satisfydepends-dummy' in `/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'.
Selecting previously deselected package pbuilder-satisfydepends-dummy.
(Reading database ... 11231 files and directories currently installed.)
Unpacking pbuilder-satisfydepends-dummy (from .../pbuilder-satisfydepends-dummy.deb) ...
dpkg: dependency problems prevent configuration of pbuilder-satisfydepends-dummy:
 pbuilder-satisfydepends-dummy depends on python; however:
  Package python is not installed.
 pbuilder-satisfydepends-dummy depends on debhelper (>= 7.4); however:
  Package debhelper is not installed.
 pbuilder-satisfydepends-dummy depends on python-support; however:
  Package python-support is not installed.
 pbuilder-satisfydepends-dummy depends on cdbs; however:
  Package cdbs is not installed.
dpkg: error processing pbuilder-satisfydepends-dummy (--install):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 pbuilder-satisfydepends-dummy
Reading package lists...
Building dependency tree...
Reading state information...
Initializing package states...
Writing extended state information...
The following partially installed packages will be configured:
  pbuilder-satisfydepends-dummy{b} 
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B of archives. After unpacking 0 B will be used.
The following packages have unmet dependencies:
  pbuilder-satisfydepends-dummy: Depends: python which is a virtual package.
                                 Depends: debhelper (>= 7.4) which is a virtual package.
                                 Depends: python-support which is a virtual package.
                                 Depends: cdbs which is a virtual package.
The following actions will resolve these dependencies:

     Remove the following packages: 
1)     pbuilder-satisfydepends-dummy



The following packages will be REMOVED:
  pbuilder-satisfydepends-dummy{a} 
0 packages upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
Need to get 0 B of archives. After unpacking 0 B will be used.
Writing extended state information...
(Reading database ... 11231 files and directories currently installed.)
Removing pbuilder-satisfydepends-dummy ...
Reading package lists...
Building dependency tree...
Reading state information...
Reading extended state information...
Initializing package states...
Aptitude couldn't satisfy the build dependencies
E: pbuilder-satisfydepends failed.
I: Copying back the cached apt archive contents
I: unmounting /var/cache/pbuilder/ccache filesystem
I: unmounting dev/pts filesystem
I: unmounting proc filesystem
 -> Cleaning COW directory
  forking: rm -rf /var/cache/pbuilder/build//cow.18473 
$



For a while, I thought that I could avert the removal of
pbuilder-satisfydepends-dummy by pre-loading the bulk of the required
packages via the --update options to pbuilder/cowbuilder, but that
simply failed. I have attached my custom .pbuilderrc-squeeze.


I feel confused.




Kind regards,
--Toni++

# this is your configuration file for pbuilder.
# the file in /usr/share/pbuilder/pbuilderrc is the default template.
# /etc/pbuilderrc is the one meant for editing.
#
# read pbuilderrc.5 document for notes on specific options.

DISTRIBUTION=squeeze

# BASETGZ=/mounts/vmachines/debian/squeeze/base-squeeze-i386.tgz
# BASETGZ=/mounts/vmachines/debian/squeeze/base-squeeze-i386.tgz
BASETGZ=/var/cache/pbuilder/base-squeeze.tgz
BASEPATH=/var/cache/pbuilder/base-squeeze.cow

#EXTRAPACKAGES=gcc3.0-athlon-builder
#export DEBIAN_BUILDARCH=athlon
# BUILDPLACE=/var/cache/pbuilder/build/
### disable this for now:
# BUILDPLACE=/home/toni/mnt/debian/pbuilder/sid/root
MIRRORSITE=http://192.168.2.10:9999/debian
# MIRRORSITE=http://ftp.de.debian.org/debian
NONUSMIRRORSITE="http://ftp.de.debian.org/debian-non-US";
# OTHERMIRROR="deb http://ftp.de.debian.org/debian/ main non-free contrib"
OTHERMIRROR="deb http://ftp.de.debian.org/debian/ squeeze main"

#export http_proxy=http://your-proxy:8080/
USEPROC=yes
USEDEVPTS=yes
USEDEVFS=no
### disable this for now:
#BUILDRESULT=/home/toni/mnt/debian/pbuilder/sid/result/

# specifying the distribution forces the distribution on "pbuilder update"
#specify the cache for APT 
#APTCACHE="/home/toni/mnt/debian/pbuilder/sid/aptcache/"
APTCACHEHARDLINK="yes"
REMOVEPACKAGES="lilo"
#HOOKDIR="/usr/lib/pbuilder/hooks"
HOOKDIR=""

# make debconf not interact with user
export DEBIAN_FRONTEND="noninteractive"

DEBEMAIL="Toni Mueller <toni@debian.org>"

#for pbuilder debuild
BUILDSOURCEROOTCMD="fakeroot"
PBUILDERROOTCMD="sudo"

#default is to build everything. Passed on to dpkg-buildpackage
#DEBBUILDOPTS="-b"
DEBBUILDOPTS="-i -us -uc"

#APT configuration files directory
#APTCONFDIR="/etc/apt"
APTCONFDIR=""

# the username and ID used by pbuilder, inside chroot. Needs fakeroot, really
BUILDUSERID=7000
BUILDUSERNAME=pbuilder

EXTRAPACKAGES="apt-utils python  python-support  debhelper cdbs netbase ifupdown autotools-dev libgd2-noxpm-dev libgeoip-dev liblua5.1-dev libmhash-dev libssl-dev libpcre3-dev libperl-dev libxslt1-dev zlib1g-dev libperl5.10 libreadline-dev"


# BINDMOUNTS is a space separated list of things to mount
# inside the chroot.
BINDMOUNTS=""

Reply to: