empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--testing]] [[--login-after-fail]] [[--build] | [build]]
empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--testing]] [[--create] | [create]]
empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--testing]] [[--save-after-login]] [[--login] | [login ]]
empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--testing]] [[--update] | [update]]
empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--login-after-fail]] [[--autobuild] | [autobuild]]
empdebuild [[-a] | [--arch ] ARCHITECTURE] [[--clean] | [clean]]
Note that empdebuild does not support all the options available to pbuilder.
empdebuild is an Emdebian version of pdebuild, building Emdebian packages in a chroot using code from pbuilder. The Emdebian chroot includes the cross-building toolchain from Emdebian for the requested architecture and includes support for installing cross versions of package dependencies via apt-cross with all the advantages of a chroot - identification of missing dependencies and the ability to build packages without installing the dependencies on the main system, e.g. to support a buildd.
empdebuild creates a chroot for the same architecture as the system running empdebuild and then installs a cross-building toolchain from Emdebian using the dpkg-cross default architecture or the specified architecture. This has some important results:
The chroot is a Debian system running emdebian-tools
and is equivalent to a typical installation of emdebian-tools
after emsetup has been completed
successfully. This includes installing perl and debconf inside the chroot.
A suitable Emdebian toolchain will be installed in the chroot.
The same cache files are needed inside the chroot as would be needed on the main system - cross-built binaries cannot be run within the the chroot. All the normal emdebian patch files will be needed.
This is a full build system with native and cross compilers, development packages, autotools and subversion. It is NOT suitable for installation on any device. Use emsandbox instead.
The chroot disables the installation of recommended packages by apt using the Install-Recommends "false" option.
Use emsandbox to create cross chroots (where the chroot is built for a different architecture to the system running the chroot), e.g. to prepare a rootfs for installation on an arm device using emdebian-tools installed on i386, amd64 etc. See emsandbox (1).
--build|build(to provide) similar functionality to pdebuild for Emdebian - copies the source into the chroot and runs a build using emdebuild.
Use --login-after-fail to debug a failed build.
If emdebuild fails inside the chroot,
empdebuild will then open a shell at the point
of failure, allowing you to debug the build session with the active data.
--create|createRuns debootstrap with a modified suite rule set to create a basic Emdebian environment, including emdebian-tools and an Emdebian toolchain for the default or specified architecture.
Checks for an existing chroot and exits if one is found - either use
--update or move the old chroot out of the way.
--login|loginLogin to the chroot. Unless --save-after-login is used,
changes made within the chroot will be lost.
When setting up any chroot, debconf is set to use the default values
and this leads to dpkg-cross being set to
None as the default cross building architecture.
When logged into the chroot, always specify the --arch
option to apt-cross and all
emdebian-tools scripts.
--update|updateUpdates the Emdebian environment, including emdebian-tools and
an Emdebian toolchain for the default or specified architecture. Depending on
the status of gcc-?.? in Debian, there can be problems updating the cross
building toolchain at this stage. If you get reports of broken packages
or toolchain packages that fail to install, allow the update to continue as
normal, then login to the chroot with the --save-after-login
option. If the problem relates to a package named $PACKAGE-$ARCH-cross
not $PACKAGE-$ARCHTYPE ($ARCHTYPE for arm = arm-linux-gnu), this
package is handled by dpkg-cross and apt-cross.
Use apt-cross -a $ARCH -v -i $PACKAGE (omit the -$ARCH-cross suffix)
to update such packages ahead of the Emdebian repository. Use
apt-get dist-upgrade and emsetup -a $ARCH --yes
to complete the upgrade. Type 'exit' or use 'Ctrl-D' to exit from the chroot and
the updated packages will be saved alongside the updated chroot.
--clean|cleanUses pbuilder functions to clean the chroot build place,
removing any previous build environments. In some situations, a stale
build environment may still contain active mounts for
proc or dev/pts
and these will result in Device or resource busy errors.
To umount the relevant points, look for your Emdebian working directory being
listed in the output of mount and pass that
directory name to:
$ sudo umount PATH
Once umounted, either remove the files manually or run sudo empdebuild
--clean again.
-a|--arch ARCHITECTUREOverride the dpkg-cross default architecture for this operation on the chroot. The Emdebian toolchain in the chroot will be upgraded (or installed if the chroot contains a toolchain for a different architecture).
--testing
Create, update, login or build a package within a chroot based on Debian testing, not Debian unstable. This is a fallback option for the times when Debian unstable transitions make it impossible to install a cross-building toolchain or update the existing toolchain.
--save-after-login
Login to the chroot and allow changes made within the chroot to persist
into subsequent sessions. Only supported in conjunction with
login|--login.
--login-after-fail
Login to the chroot if emdebuild fails
within the chroot, at the point where the build failed. Chroot cross builds
can involve a protracted setup phase which can be hard to replicate
outside the chroot. Use this option to find out why a chroot build failed
when a normal build succeeded. Only supported in conjunction with
build|--build.
-h|--helpprint the usage message and exit.
--version
print the usage message and exit.
empdebuild was written
by Neil Williams <codehelp@debian.org>.
This manual page was written by Neil Williams
<codehelp@debian.org>