From 9b44a68736399dd78eb9c04d3aba96f80ca70ac3 Mon Sep 17 00:00:00 2001 From: dancer Date: Wed, 24 May 2006 09:02:25 +0000 Subject: initial cowbuilder support in pdebuild pbuilder supports pdebuild/cowbuilder login/execute/update/create etc. can also be --login/--execute/--update/--create etc. to cater for cowbuilder documentation updates / XML typesetting fixes. manpage fixes / spellchecking generally what I did while I was on plane trip from Debconf Mexico to Japan. --- ChangeLog | 49 ++++ Documentation/pbuilder-doc.xml | 610 +++++++++++++++++++++++------------------ debian/changelog | 7 +- pbuilder | 16 +- pbuilder-buildpackage-funcs | 2 +- pbuilder-modules | 8 +- pbuilder-user-mode-linux.1 | 2 +- pbuilder.8 | 5 +- pbuilderrc.5 | 13 +- pdebuild | 4 +- pdebuild-checkparams | 9 + pdebuild-user-mode-linux.1 | 6 +- pdebuild.1 | 12 +- 13 files changed, 447 insertions(+), 296 deletions(-) diff --git a/ChangeLog b/ChangeLog index 6beb98d..26131d7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,52 @@ +2006-05-24 Junichi Uekawa + + * pbuilder-buildpackage-funcs: quiet down cowprotect, it's giving + out useless output, like the following: + + Copying back the cached apt archive contents + /var/cache/pbuilder/build/cow.12278/etc/passwd + /var/cache/pbuilder/build/cow.12278/etc/group + Copying source file + + + * pbuilder.8: fix pbuilder execute command-line specification to + reflect that script can receive command-line parameters. + + * pdebuild: add a in invocation to pbuilder execute "--", to avoid + reorder in cowbuilder, and still work with pbuilder. + + * pdebuild.1: document --pbuilder option. + + * pbuilderrc.5: document the new option + + * pdebuild-checkparams: --pbuilder option. Use pbuilder as default. + It is possible to use cowbuilder. + + * pbuilder: add --XXX options as compatibility options for cowbuilder. + + * pdebuild (ARCHITECTURE): use PDEBUILD_PBUILDER instead of calling pbuilder directly, + and use cowdancer-compatible command-line options. + + * Documentation/pbuilder-doc.xml: generally spellcheck, and revise. + + * pdebuild.1: spellcheck + + * pdebuild-user-mode-linux.1: spellcheck + + * pbuilderrc.5: spellcheck + + * pbuilder-modules: remove mention of potato/woody, since they + probably don't work + (pbuilder-options): remove potato/woody. + + * pbuilder.8: remove woody from supported list of distributions, + we know dpkg from then doesn't really work with modern kernel. + (well, they do, but I don't want this documented/advertised) + + * pbuilder-user-mode-linux.1: spellcheck + + * pbuilder.8: spellcheck + 2006-05-22 Junichi Uekawa * debian/TODO: update TODO, amd64-x86 cross build is documented and functional. diff --git a/Documentation/pbuilder-doc.xml b/Documentation/pbuilder-doc.xml index 149f57d..611271e 100644 --- a/Documentation/pbuilder-doc.xml +++ b/Documentation/pbuilder-doc.xml @@ -4,7 +4,7 @@ and the latest version is found in CVS repository. --> - 2006-3-8 + 2006-5-24 pbuilder User's Manual pbuilder-doc Usage and operations @@ -45,7 +45,7 @@ installed. - The primary aim of pbuilder is different from other + The primary aim of pbuilder is different from other auto-building systems in Debian in that its aim is not to try to build as many packages as possible. It does not try to guess @@ -55,7 +55,7 @@ In this way, pbuilder tries to ensure that packages - tested against pbuilder will build properly in + tested against pbuilder will build properly in most Debian installations, hopefully resulting in a good overall Debian source-buildability. @@ -112,11 +112,11 @@ will update the chroot image. It will extract the chroot, invoke apt-get update and apt-get dist-upgrade inside the - chroot, and then recreate the base tarball. + chroot, and then recreate the base tar-ball. It is possible to switch the distribution which the chroot - tarball is targeted at at this point. + tar-ball is targeted at at this point. Specify to change the distribution to sid. @@ -184,9 +184,9 @@ There is a slightly different mode of operation available - in pdebuild since version 0.97. pdebuild usually runs + in pdebuild since version 0.97. pdebuild usually runs debian/rules clean outside of the chroot; - however, it is possible to change the behavior to run it + however, it is possible to change the behaviour to run it inside the chroot with the . It will try to bind mount the working directory inside chroot, @@ -198,7 +198,7 @@ Satisfies build-dependency inside the chroot before creating source package. - (which is a good point that current pdebuild cannot do). + (which is a good point that current pdebuild cannot do). @@ -206,8 +206,8 @@ from inside the chroot. - Building with pdebuild does not guarantee - that it works with pbuilder. + Building with pdebuild does not guarantee + that it works with pbuilder. If making the source package fails, @@ -235,12 +235,12 @@ /etc/pbuilderrc and ${HOME}/.pbuilderrc - are read in when pbuilder is invoked. + are read in when pbuilder is invoked. The possible options are documented in the pbuilderrc.5 manual page. - It is useful to use --configfile option to load up a pre-set + It is useful to use option to load up a preset configuration file when switching between configuration files for different distributions. @@ -270,17 +270,17 @@ packages that are being built with pbuilder to affect the environment outside the chroot. When BUILDUSERNAME configuration option is also set, - pbuilder will use the specified user name and fakeroot for building packages, + pbuilder will use the specified user name and fakeroot for building packages, instead of running as root inside chroot. - Even when using the fakerooting method, pbuilder will run with + Even when using the fakerooting method, pbuilder will run with root privilege when it is required. For example, when installing - packages to the chroot, pbuilder will run under root privilege. + packages to the chroot, pbuilder will run under root privilege. - To be able to invoke pbuilder without being + To be able to invoke pbuilder without being root, you need to use user-mode-linux, as explained in . @@ -288,7 +288,7 @@ Using pbuilder for back-porting - pbuilder can be used for back-porting software from + pbuilder can be used for back-porting software from the latest Debian distribution to the older stable distribution, by using a chroot that contains an image of the older distribution, and building packages inside the @@ -317,14 +317,14 @@ Mass-building packages - pbuilder can be automated, because its operations are + pbuilder can be automated, because its operations are non-interactive. - It is possible to run pbuilder through multiple packages + It is possible to run pbuilder through multiple packages non-interactively. Several such scripts are known to exist. Junichi Uekawa has been running such a script since 2001, and has been filing bugs on packages that fail the - test of pbuilder. There were several problems with auto-building: + test of pbuilder. There were several problems with auto-building: @@ -343,18 +343,18 @@ - Most of the initial bugs have been resolved in the pbuilder + Most of the initial bugs have been resolved in the pbuilder sweep done around 2002, but these transitional problems which affect a large portion of Debian Archive do arise from time to time. Regression tests have their values. A script that was used by Junichi Uekawa is now included in - the pbuilder distribution, as pbuildd.sh. + the pbuilder distribution, as pbuildd.sh. It is available in /usr/share/doc/pbuilder/examples/pbuildd/ and its configuration is in /etc/pbuilder/pbuildd-config.sh. It should be easy enough to set up for people who are used to - pbuilder. It has been running for quite a while, and it should be + pbuilder. It has been running for quite a while, and it should be possible to set the application up on your system also. However, it is a new introduction, and please file bugs to the Debian BTS if you know of possible problems, @@ -373,7 +373,7 @@ Because you are running random build scripts, it is better to use - the fakeroot option of pbuilder, to avoid running the build + the fakeroot option of pbuilder, to avoid running the build under root privilege. @@ -393,7 +393,7 @@ Auto-backporting scripts - There are some people who use pbuilder to automatically back-port + There are some people who use pbuilder to automatically back-port a subset of packages to the stable distribution. @@ -405,7 +405,7 @@ Using pbuilder for automated testing of packages - pbuilder can be used for automated testing of packages. + pbuilder can be used for automated testing of packages. It has the feature of allowing hooks to be placed, and these hooks can try to install packages inside the chroot, or run them, or whatever else that @@ -413,7 +413,7 @@ - Automatic install-remove-upgrade-remove-install-purge-upgrade-purge testsuite (distributed as an example, B91dpkg-i), + Automatic install-remove-upgrade-remove-install-purge-upgrade-purge test-suite (distributed as an example, B91dpkg-i), or just check that everything installs somewhat (execute_installtest.sh). @@ -424,7 +424,7 @@ Automatic debian-test of the package? The debian-test package has been removed from Debian. - A pbuilder implementation can be found as + A pbuilder implementation can be found as debian/pbuilder-test directory, implemented through B92pkg-test script. @@ -462,35 +462,38 @@ export DEBIAN_BUILDGCCVER=3.2 Using User-mode-linux with pbuilder - NOTE that since October 2004, pbuilder for user-mode-linux is - not distributed, since user-mode-linux itself is broken in - Debian. A functional user-mode-linux will hopefully be fixed - before Debian etch release, but it is not quite determined yet - if pbuilder-uml will be ready for etch. + NOTE that since October 2004, pbuilder for + user-mode-linux is not distributed, since + user-mode-linux itself is broken in Debian. + A functional user-mode-linux will hopefully + be fixed before Debian etch release, but it is not quite + determined yet if pbuilder-user-mode-linux + will be ready for etch. - It is possible to use user-mode-linux - by invoking pbuilder-uml - instead of pbuilder. - pbuilder-uml doesn't require - root privileges, and it uses - the copy-on-write (COW) disk access method of User-mode-linux - which typically makes it much faster - than the traditional pbuilder. + It is possible to use user-mode-linux by invoking + pbuilder-user-mode-linux instead of + pbuilder. + pbuilder-user-mode-linux doesn't require root + privileges, and it uses the copy-on-write (COW) disk access + method of User-mode-linux which typically + makes it much faster than the traditional + pbuilder. - User-mode-linux is a somewhat less proven platform - than the standard Unix tools which + User-mode-linux is a somewhat less proven + platform than the standard Unix tools which pbuilder relies on - (chroot, - tar, - and gzip) - but mature enough to support pbuilder-uml - since its version 0.59. - And since then, pbuilder-uml has seen a rapid evolution. + (chroot, tar, and + gzip) but mature enough to support + pbuilder-user-mode-linux since its version + 0.59. And since then, + pbuilder-user-mode-linux has seen a rapid + evolution. - The configuration of pbuilder-uml goes in three steps: + The configuration of pbuilder-user-mode-linux + goes in three steps: Configuration of user-mode-linux @@ -506,13 +509,14 @@ export DEBIAN_BUILDGCCVER=3.2 Configuring user-mode-linux - UML isn't completely trivial to set up. - It would probably be useful to acquaint yourself with it a bit - before attempting to use rootstrap or pbuilder-uml. - For details, - read /usr/share/doc/uml-utilities/README.Debian - and the user-mode-linux documentation. - (It's in a separate package, user-mode-linux-doc.) + user-mode-linux isn't completely trivial to set up. It would + probably be useful to acquaint yourself with it a bit before + attempting to use rootstrap or + pbuilder-user-mode-linux. For details, + read + /usr/share/doc/uml-utilities/README.Debian + and the user-mode-linux documentation. (It's in a separate + package, user-mode-linux-doc.) user-mode-linux requires @@ -609,7 +613,7 @@ PBUILDER_UML_IMAGE="/home/dancer/uml-image" - Run pbuilder-user-mode-linux create --distribution sid to create the image. + Run pbuilder-user-mode-linux to create the image. Try running pbuilder-user-mode-linux build. @@ -618,28 +622,30 @@ PBUILDER_UML_IMAGE="/home/dancer/uml-image" - Considerations for running pbuilder-uml + Considerations for running pbuilder-user-mode-linux - pbuilder-user-mode-linux emulates most of pbuilder, but there + pbuilder-user-mode-linux emulates most of pbuilder, but there are some differences. - pbuilder-user-mode-linux does not support all options of pbuilder + pbuilder-user-mode-linux does not support all options of pbuilder properly yet. This is a problem, and will be addressed as specific areas are discovered. - /tmp is handled differently inside pbuilder-uml. - In pbuilder-uml, /tmp is mounted as tmpfs inside UML, - so accessing files under /tmp from outside user-mode-linux - does not work. - It affects options like - , - and when trying to build packages placed under /tmp. + /tmp is handled differently inside + pbuilder-user-mode-linux. In + pbuilder-user-mode-linux, + /tmp is mounted as tmpfs inside UML, + so accessing files under /tmp from + outside user-mode-linux does not work. It affects options + like , and + when trying to build packages placed under + /tmp. @@ -647,8 +653,8 @@ PBUILDER_UML_IMAGE="/home/dancer/uml-image" Parallel running of pbuilder-user-mode-linux - To run pbuilder-uml in parallel on a system, there are a few things - to bear in mind. + To run pbuilder-user-mode-linux in parallel + on a system, there are a few things to bear in mind. @@ -657,9 +663,9 @@ PBUILDER_UML_IMAGE="/home/dancer/uml-image" - If you are not using slirp, UML processes which are + If you are not using slirp, user-mode-linux processes which are running in parallel need to have different IP addresses. - Just trying to run the pbuilder-uml + Just trying to run the pbuilder-user-mode-linux several times will result in failure to access the network. But something like the following will work: @@ -674,28 +680,31 @@ done - Using pbuilder-uml as a wrapper script to start up a virtual machine + Using pbuilder-user-mode-linux as a wrapper script to start up a virtual machine - It is possible to use pbuilder-uml for other uses than just building Debian - packages. - pbuilder-user-mode-linux login - will let a user use a shell inside the user-mode-linux - pbuilder base image, - and pbuilder-user-mode-linux execute will - allow the user to execute a script inside the image. + It is possible to use + pbuilder-user-mode-linux for other uses + than just building Debian packages. + pbuilder-user-mode-linux + will let a user use a shell + inside the user-mode-linux pbuilder base + image, and pbuilder-user-mode-linux + will allow the user to + execute a script inside the image. You can use the script to install ssh and add a new user, - so that it is possible to access inside the UML through ssh. + so that it is possible to access inside the user-mode-linux through ssh. Note that it is not possible to use a script from - /tmp due to the way pbuilder-uml mounts - a tmpfs at /tmp. + /tmp due to the way + pbuilder-user-mode-linux mounts a tmpfs at + /tmp. The following example script may be useful in starting a sshd - inside uml. + inside user-mode-linux. #!/bin/bash @@ -724,33 +733,33 @@ read pbuilder create fails - It often happens that pbuilder cannot create the latest chroot. - Try upgrading pbuilder and debootstrap. + It often happens that pbuilder cannot create the latest chroot. + Try upgrading pbuilder and debootstrap. It is currently only possible to create software that handles the past. Future prediction is a feature which may be added later after we have become comfortable with the past. - There are people who occasionally backport debootstrap to stable + There are people who occasionally back port debootstrap to stable versions; hunt for them. When there are errors with the debootstrap phase, the debootstrap script needs to be fixed. - pbuilder does not provide a way to work around debootstrap. + pbuilder does not provide a way to work around debootstrap. Directories that cannot be bind-mounted - Because of the way pbuilder works, there are several directories - which cannot be bind-mounted when running pbuilder. - The directories include /tmp, - /var/cache/pbuilder, - and system directories such as /etc and - /usr. - The recommendation is to use directories under the user's home directory - for bind-mounts. + Because of the way pbuilder works, there + are several directories which cannot be bind-mounted when + running pbuilder. The directories include + /tmp, + /var/cache/pbuilder, and system + directories such as /etc and + /usr. The recommendation is to use + directories under the user's home directory for bind-mounts. @@ -769,20 +778,21 @@ $ cp C10shell ~/loginhooks/E10shell $ sudo pbuilder update --hookdir ~/loginhooks/E10shell - It is also possible to add --save-after-exec - and/or --save-after-login options + It is also possible to add + and/or options to the pbuilder login session to accomplish the goal. - It is possible to add the --uml-login-nocow option - to pbuilder-user-mode-linux login session + It is possible to add the option + to pbuilder-user-mode-linux session as well. Setting BUILDRESULTUID for sudo sessions - It is possible to set BUILDRESULTUID=$SUDO_UID in pbuilderrc - to set the proper BUILDRESULTUID when using sudo. + It is possible to set + BUILDRESULTUID=$SUDO_UID in pbuilderrc to set + the proper BUILDRESULTUID when using sudo. @@ -799,25 +809,25 @@ $ sudo pbuilder update --hookdir ~/loginhooks/E10shell An example script is provided as - examples/D10tmp with pbuilder. + examples/D10tmp with pbuilder. - Creating a shortcut for running pbuilder with a specific distribution + Creating a shortcut for running <command>pbuilder</command> with a specific distribution - When working with multiple chroots, it would be nice to work with - scripts that reduce the amount of typing. - An example script - pbuilder-distribution.sh is provided as an example. - Invoking the script as pbuilder-woody will invoke - pbuilder with a woody chroot. + When working with multiple chroots, it would be nice to work + with scripts that reduce the amount of typing. An example + script pbuilder-distribution.sh is + provided as an example. Invoking the script as + pbuilder-sarge will invoke + pbuilder with a sarge chroot. Using special apt sources lists, and local packages - If you have some very specialized requirements on your - apt setup inside pbuilder, + If you have some very specialised requirements on your + apt setup inside pbuilder, it is possible to specify that through the option. @@ -825,7 +835,7 @@ $ sudo pbuilder update --hookdir ~/loginhooks/E10shell - To use the local filesystem instead of http, it is necessary to do + To use the local file system instead of HTTP, it is necessary to do bind-mounting. is a command-line option useful for such cases. @@ -870,9 +880,10 @@ cd /var/cache/pbuilder/result/ Different bash prompts inside pbuilder login - To make distinguishing bash prompts inside pbuilder - easier, it is possible to set environment variables such as PS1 - inside pbuilderrc + To make distinguishing bash prompts inside + pbuilder easier, it is possible to set + environment variables such as PS1 inside + pbuilderrc With versions of bash more recent than 2.05b-2-15, @@ -896,32 +907,33 @@ cd /var/cache/pbuilder/result/ Using /var/cache/apt/archives for the package cache - For the help of low-bandwidth systems, - it is possible to use /var/cache/apt/archives as the - package cache. - Just specify it instead of the default /var/cache/pbuilder/aptcache. + For the help of low-bandwidth systems, it is possible to use + /var/cache/apt/archives as the package + cache. Just specify it instead of the default + /var/cache/pbuilder/aptcache. - It is however not possible to do so currently with the user-mode-linux - version of pbuilder, because /var/cache/apt/archives - is usually only writable by root. + It is however not possible to do so currently with the + user-mode-linux version of pbuilder, + because /var/cache/apt/archives is + usually only writable by root. - Use of dedicated tools such as apt-proxy is recommended, since caching of packages - would benefit the system outside the scope of pbuilder. + Use of dedicated tools such as apt-proxy is recommended, since + caching of packages would benefit the system outside the scope + of pbuilder. - - pbuilder backported to stable Debian releases + + pbuilder back ported to stable Debian releases - Currently stable backport to sarge is not known to be available. - It should hopefully soon be available. + Currently stable back port of pbuilder is avialable at backports.org. Warning about LOGNAME not being defined - You might see a lot of warning messages when running pbuilder. + You might see a lot of warning messages when running pbuilder. @@ -929,15 +941,16 @@ cd /var/cache/pbuilder/result/ - It is currently safe to ignore this warning message. - Please report back if you find any problem with having LOGNAME unset. - Setting LOGNAME caused a few problems when invoking chroot. + It is currently safe to ignore this warning message. Please + report back if you find any problem with having LOGNAME unset. + Setting LOGNAME caused a few problems when invoking + chroot. Cannot Build-conflict against an essential package - pbuilder does not currently allow Build-Conflicts against + pbuilder does not currently allow Build-Conflicts against essential packages. It should be obvious that essential packages should not be removed from a working Debian system, and a source @@ -948,28 +961,29 @@ cd /var/cache/pbuilder/result/ Avoiding the "ln: Invalid cross-device link" message - By default, pbuilder uses hard links to manage the pbuilder package cache. - It is not possible to make hard links across different devices; - and thus this error will occur, depending on your set up. - If this happens, set APTCACHEHARDLINK=no - in your pbuilderrc file. + By default, pbuilder uses hard links to + manage the pbuilder package cache. It is + not possible to make hard links across different devices; and + thus this error will occur, depending on your set up. If this + happens, set APTCACHEHARDLINK=no in your + pbuilderrc file. Using fakechroot - It is possible to use fakechroot instead of being root - to run pbuilder; however, several things make this impractical. - fakechroot overrides library loads and tries to - override default libc functions when providing the functionality of - virtual chroot. - However, some binaries do no use libc to function, or override the overriding - provided by fakechroot. - One example is ldd. - Inside fakechroot, - ldd - will check the library dependency outside of the chroot, - which is not the expected behavior. + It is possible to use fakechroot instead of + being root to run pbuilder; however, + several things make this impractical. + fakechroot overrides library loads and + tries to override default libc functions when providing the + functionality of virtual chroot. However, + some binaries do no use libc to function, or override the + overriding provided by fakechroot. One + example is ldd. Inside + fakechroot, ldd will + check the library dependency outside of the chroot, which is + not the expected behaviour. To work around the problem, fakechroot provides a patch for debootstrap. @@ -982,7 +996,7 @@ cd /var/cache/pbuilder/result/ Using debconf inside pbuilder sessions - To use debconf inside pbuilder, setting DEBIAN_FRONTEND to + To use debconf inside pbuilder, setting DEBIAN_FRONTEND to readline in pbuilderrc should work. Setting it to dialog should also work, but make sure whiptail or dialog is installed inside the chroot. @@ -991,20 +1005,20 @@ cd /var/cache/pbuilder/result/ nodev mount options hinder pbuilder activity - If you see messages such as this when building a chroot, you are mounting the filesystem with + If you see messages such as this when building a chroot, you are mounting the file system with the nodev option. /var/lib/dpkg/info/base-files.postinst: /dev/null: Permission denied - You will also have problems if you mount the filesystem with + You will also have problems if you mount the file system with the noexec option, or nosuid. - Make sure you do not have these flags set when mounting the filesystem for + Make sure you do not have these flags set when mounting the file system for /var/cache/pbuilder or $BUILDPLACE. - This is not a problem when using User-mode-linux. + This is not a problem when using user-mode-linux. See @@ -1015,38 +1029,43 @@ cd /var/cache/pbuilder/result/ pbuilder is slow - pbuilder is often slow. The slowest part of pbuilder is extracting the tar.gz every time - pbuilder is invoked. That can be avoided by using pbuilder-user-mode-linux. - pbuilder-user-mode-linux uses - COW filesystem, and thus does not need to clean up and recreate the root filesystem. + pbuilder is often slow. The slowest part of + pbuilder is extracting the tar.gz every + time pbuilder is invoked. That can be + avoided by using pbuilder-user-mode-linux. + pbuilder-user-mode-linux uses COW file + system, and thus does not need to clean up and recreate the + root file system. - pbuilder-user-mode-linux is slower in executing the actual build system, due to the - usual user-mode-linux overhead for system calls. It is more friendly to the hard drive. + pbuilder-user-mode-linux is slower in + executing the actual build system, due to the usual + user-mode-linux overhead for system + calls. It is more friendly to the hard drive. - pbuilder with cowdancer is under development, to allow - pbuilder to start up faster; when it is ready, it should + pbuilder with cowdancer is under development, to allow + pbuilder to start up faster; when it is ready, it should be able to replace the current setup. Creating a chroot reminder - You may want a sign that you are inside a chroot, when - working with chroot. - Check out the examples/F90chrootmemo - hook script. - It will create a file called /CHROOT - inside your chroot. + You may want a sign that you are inside a chroot, when working + with chroot. Check out the + examples/F90chrootmemo hook script. It + will create a file called /CHROOT inside + your chroot. + + + + + + + + + + + + + + + + + + + + diff --git a/debian/changelog b/debian/changelog index 3937825..938ccea 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,9 +8,12 @@ pbuilder (0.153) UNRELEASED; urgency=low situation. * pbuilder-doc.xml: update documentation to add an example snippet for using locally built packages from pbuilder. - And other minor updates. + And other minor updates, including spellchecking. + * manpages: spellcheck. + * cowdancer support, pbuilder support cowbuilder. + * quiet down cowprotect message. - -- Junichi Uekawa Wed, 17 May 2006 11:46:36 +0900 + -- Junichi Uekawa Wed, 24 May 2006 09:12:43 +0900 pbuilder (0.152) unstable; urgency=low diff --git a/pbuilder b/pbuilder index 28170b7..ed563dc 100755 --- a/pbuilder +++ b/pbuilder @@ -26,19 +26,19 @@ export PBCURRENTCOMMANDLINEOPERATION="$1" umask 0022 case "$1" in - create) + --create|create) shift; /usr/lib/pbuilder/pbuilder-createbuildenv "$@" ;; - update) + --update|update) shift ; /usr/lib/pbuilder/pbuilder-updatebuildenv "$@" ;; - build) + --build|build) shift ; /usr/lib/pbuilder/pbuilder-buildpackage "$@" ;; - clean) + --clean|clean) shift; . /usr/lib/pbuilder/pbuilder-checkparams if [ -n "$BASEBUILDPLACE" ]; then @@ -50,7 +50,7 @@ case "$1" in clean_subdirectories "$APTCACHE" || true fi ;; - login) + --login|login) shift . /usr/lib/pbuilder/pbuilder-checkparams . /usr/lib/pbuilder/pbuilder-runhooks @@ -88,7 +88,7 @@ File extracted to: $BUILDPLACE fi fi ;; - execute) + --execute|execute) # try to execute arbitrary program. shift . /usr/lib/pbuilder/pbuilder-checkparams @@ -130,7 +130,7 @@ File extracted to: $BUILDPLACE fi fi ;; - dumpconfig) + --dumpconfig|dumpconfig) shift . /usr/lib/pbuilder/pbuilder-checkparams . /usr/lib/pbuilder/pbuilder-runhooks @@ -145,7 +145,7 @@ File extracted to: $BUILDPLACE env; echo " -> end dump config" ;; - debuild) + --debuild|debuild) shift "$0" execute "$@" /usr/lib/pbuilder/pdebuild-internal ;; diff --git a/pbuilder-buildpackage-funcs b/pbuilder-buildpackage-funcs index 179ba67..3412bfe 100644 --- a/pbuilder-buildpackage-funcs +++ b/pbuilder-buildpackage-funcs @@ -70,7 +70,7 @@ function cowprotect () { # a hack for cowdancer, used when a file is edited in-place; # Copy the file to create a new i-node so that hardlinked original is intact for A in "$@"; do - if readlink -f "$A"; then + if readlink -f "$A" > /dev/null; then A=$(readlink -f "$A") mv "$A" "$A"~ cp -a "$A"~ "$A" diff --git a/pbuilder-modules b/pbuilder-modules index 2f864cd..16fb4ce 100644 --- a/pbuilder-modules +++ b/pbuilder-modules @@ -27,10 +27,10 @@ pbuilder [operation] [pbuilder-options] pdebuild [pdebuild-options] -- [pbuilder-options] command lines: -pbuilder create [--basetgz base.tgz-path] [--distribution potato|woody|sarge|etch|sid|experimental] +pbuilder create [--basetgz base.tgz-path] [--distribution sarge|etch|sid|experimental] Creates a base.tgz -pbuilder update [--basetgz base.tgz-path] [--distribution potato|woody|sarge|etch|sid|experimental] +pbuilder update [--basetgz base.tgz-path] [--distribution sarge|etch|sid|experimental] Updates a base.tgz pbuilder build [--basetgz base.tgz-path] pbuilder_2.2.0-1.dsc @@ -40,7 +40,7 @@ pbuilder clean Cleans the temporal build directory. pbuilder login -pbuilder execute [command] +pbuilder execute -- [command] [command-options] Logs in to the build environment and execute command. pbuilder dumpconfig @@ -52,7 +52,7 @@ pbuilder-options: --mirror [mirror location] --othermirror [other mirror location in apt deb-line format, delimited with | signs] --http-proxy [proxy] - --distribution [distribution(potato|woody|sarge|sid|etch|experimental)] + --distribution [distribution(sarge|sid|etch|experimental)] --buildresult [location-to-copy-build-result] --aptcache [location of retrieved package files] --removepackages [packages-to-remove on pbuilder create] diff --git a/pbuilder-user-mode-linux.1 b/pbuilder-user-mode-linux.1 index 29c0d23..f414688 100644 --- a/pbuilder-user-mode-linux.1 +++ b/pbuilder-user-mode-linux.1 @@ -191,7 +191,7 @@ This option is only valid when distribution is being specified, for update and build targets. The format is something like: .I "http://http.us.debian.org/debian" -which should point to your favorite mirror. +which should point to your favourite mirror. This option can optionally be omitted, and left blank, in which case, this part is skipped. diff --git a/pbuilder.8 b/pbuilder.8 index 609dfb6..fae08c3 100644 --- a/pbuilder.8 +++ b/pbuilder.8 @@ -8,7 +8,7 @@ pbuilder \- personal package builder .PP .BI "pbuilder build [" "options" "] " ".dsc-file" .PP -.BI "pbuilder execute [" "options" "] " "script" +.BI "pbuilder execute [" "options" "] -- " "script [" "script options" "]" .PP .BI "pbuilder clean" .PP @@ -146,7 +146,7 @@ This option is only valid when distribution is being specified, for update and build targets. The format is something like: .I "http://http.us.debian.org/debian" -which should point to your favorite mirror. +which should point to your favourite mirror. This option can optionally be omitted, and left blank, in which case, this part is skipped. @@ -193,7 +193,6 @@ should do. Specifies the distribution used. Currently the supported values are .B "sid" .B "sarge" -.B "woody" .B "etch" and .B "experimental". diff --git a/pbuilderrc.5 b/pbuilderrc.5 index ee11d96..9307998 100644 --- a/pbuilderrc.5 +++ b/pbuilderrc.5 @@ -1,4 +1,4 @@ -.TH "pbuilderrc" 5 "2006 May 15" "Debian" "pbuilder" +.TH "pbuilderrc" 5 "2006 May 24" "Debian" "pbuilder" .SH NAME pbuilderrc \- configuration files for personal package builder .SH DESCRIPTION @@ -325,6 +325,14 @@ and .BI "PKGNAME_LOGFILE_EXTENTION=" ".build" The extension of filename used in pkgname-logfile option. +.TP +.BI "PDEBUILD_PBUILDER=" "pbuilder" +Specify what pbuilder implementation to use for pdebuild. +The currently possible values are +.B "pbuilder" +and +.B "cowbuilder" + .SH "AUTHOR" Initial coding, and main maintenance is done by Junichi Uekawa . @@ -338,3 +346,6 @@ The homepage is available at .SH "SEE ALSO" .RI "pbuilder (" 8 "), " .RI "pdebuild (" 1 ")" + +\" LocalWords: interactiveness noninteractive pdebuild pbuilder buildd +\" LocalWords: pbuilderrc diff --git a/pdebuild b/pdebuild index ad38cfa..1756369 100644 --- a/pdebuild +++ b/pdebuild @@ -37,13 +37,13 @@ export BUILDRESULTUID=$(id -u) export BUILDRESULTGID=$(id -g) if [ "${USE_PDEBUILD_INTERNAL}" = 'yes' ]; then - ${PBUILDERROOTCMD} pbuilder execute "$@" ${EXTRA_CONFIGFILE[@]/#/--configfile } --bindmounts $(readlink -f ..) /usr/lib/pbuilder/pdebuild-internal ${PWD} --debbuildopts "${DEBBUILDOPTS}" --uid "${BUILDRESULTUID}" --gid "${BUILDRESULTGID}" + ${PBUILDERROOTCMD} ${PDEBUILD_PBUILDER} --execute "$@" ${EXTRA_CONFIGFILE[@]/#/--configfile } --bindmounts $(readlink -f ..) -- /usr/lib/pbuilder/pdebuild-internal ${PWD} --debbuildopts "${DEBBUILDOPTS}" --uid "${BUILDRESULTUID}" --gid "${BUILDRESULTGID}" else if ! dpkg-checkbuilddeps -B ; then echo "W: Unmet build-dependency in source" fi echo "dpkg-buildpackage -S -us -uc -r${BUILDSOURCEROOTCMD} $DEBBUILDOPTS" | perl -pe 's/(^|\s)-[bB](\s|$)/$1$2/g' | /bin/bash - ${PBUILDERROOTCMD} pbuilder build "$@" ${EXTRA_CONFIGFILE[@]/#/--configfile } --buildresult "${BUILDRESULT}" --debbuildopts "${DEBBUILDOPTS}" ../"${PKG_SOURCENAME}_${PKG_VERSION}".dsc + ${PBUILDERROOTCMD} ${PDEBUILD_PBUILDER} --build "$@" ${EXTRA_CONFIGFILE[@]/#/--configfile } --buildresult "${BUILDRESULT}" --debbuildopts "${DEBBUILDOPTS}" ../"${PKG_SOURCENAME}_${PKG_VERSION}".dsc fi # do signing with optional key specifier diff --git a/pdebuild-checkparams b/pdebuild-checkparams index 0b60624..6b09d09 100644 --- a/pdebuild-checkparams +++ b/pdebuild-checkparams @@ -83,6 +83,11 @@ while [ -n "$1" ]; do exec 2>&1 shift; shift; ;; + --pbuilder) + echo " -> using $2 as pbuilder" + PDEBUILD_PBUILDER="$2" + shift; shift; + ;; --help) showhelp ;; @@ -110,3 +115,7 @@ fi if [ -z "${CHROOTEXEC}" ]; then CHROOTEXEC="chroot $BUILDPLACE " fi + +if [ -z "${PDEBUILD_PBUILDER}" ]; then + PDEBUILD_PBUILDER="pbuilder" +fi diff --git a/pdebuild-user-mode-linux.1 b/pdebuild-user-mode-linux.1 index 83bc92b..adfa43f 100644 --- a/pdebuild-user-mode-linux.1 +++ b/pdebuild-user-mode-linux.1 @@ -1,4 +1,4 @@ -.TH "pdebuild\-user\-mode\-linux" 1 "2005 Jul 10" "Debian" "pbuilder" +.TH "pdebuild\-user\-mode\-linux" 1 "2006 May 24" "Debian" "pbuilder" .SH NAME pdebuild\-user\-mode\-linux \- pbuilder\-user\-mode\-linux way of doing debuild .SH SYNOPSIS @@ -7,7 +7,7 @@ pdebuild\-user\-mode\-linux \- pbuilder\-user\-mode\-linux way of doing debuild .SH "DESCRIPTION" A convenience program for .B pbuilder\-user\-mode\-linux -which invokes pbuilder after obtaining appropriate root privilate +which invokes pbuilder after obtaining appropriate root privilege in a Debian source directory. One must be inside the source tree containing the .B debian @@ -106,3 +106,5 @@ The homepage is available at .RI "pbuilder\-user\-mode\-linux (" 1 "), " .RI "pbuilderrc (" 5 "), " .RI "pbuilder\-uml.conf (" 5 ") " + +\" LocalWords: pdebuild linux pbuilder fakeroot diff --git a/pdebuild.1 b/pdebuild.1 index 2dcb450..07642e3 100644 --- a/pdebuild.1 +++ b/pdebuild.1 @@ -1,4 +1,4 @@ -.TH "pdebuild" 1 "2006 May 15" "Debian" "pbuilder" +.TH "pdebuild" 1 "2006 May 24" "Debian" "pbuilder" .SH NAME pdebuild \- pbuilder way of doing debuild .SH SYNOPSIS @@ -7,7 +7,7 @@ pdebuild \- pbuilder way of doing debuild .SH DESCRIPTION A convenience program for .B pbuilder -which invokes pbuilder after obtaining appropriate root privilate +which invokes pbuilder after obtaining appropriate root privilege in a Debian source directory. One must be inside the source tree containing the .B debian @@ -43,7 +43,7 @@ Invoke debsign at the end of pdebuild process. .BI "\-\-debsign\-k [" "key\-id" "]" Pass .B \-k -option to debsign to specify which keyid to sign. +option to debsign to specify which key-id to sign. .TP .BI "\-\-buildresult [" "Directory for build results" "]" @@ -88,6 +88,10 @@ The messages generated during execution will be written to the file, instead of messages coming to the standard output. +.TP +.BI "\-\-pbuilder [" "pbuilder" "]" +Specifies which command to invoke as pbuilder. + .TP .BI "\-\-help" @@ -139,3 +143,5 @@ The homepage is available at .SH "SEE ALSO" .RI "pbuilder (" 8 "), " .RI "pbuilderrc (" 5 ") " + +\" LocalWords: pdebuild pbuilder debuild debian debsign pdebuid -- cgit v1.2.3