Hi Peter,

On Tue, May 17, 2016 at 09:37:31AM +0200, Peter Spiess-Knafl wrote:
> Do you have any more documentation on cross building Debian packages?
> Usually I do it using qemu and pbuilder.

I fear that cross building with pbuilder is not yet implemented.

In general, sbuild is a good choice for cross building (in unstable).
Once you have sbuild up and running for native builds, all you do for
selecting a cross build is pass "--host=$some_debian_architecture".

Note that building libjsoncpp will still run into #815172 and make the
build fail. Thats out of your realm. With sbuild, it can be worked
around with (example for armhf):

    --chroot-setup-command "dpkg --add-architecture armhf && apt-get update && 
apt-get install -y libc6-dev:armhf libstdc++-5-dev:armhf"

Building without pbuilder or sbuild is possible as well. The relevant
option for dpkg-buildpackage is --host-arch. For installing
Build-Depends manually, I recommend

    apt-get build-dep -A$some_debian_architecture --arch-only 
./path/to/sourcepkg

All of this refers to using unstable and will not work that well in
other distributions. If in doubt, I welcome you to ask on IRC oftc
#debian-bootstrap or debian-cr...@lists.debian.org. The Debian wiki also
has lots of pages on the matter, though at this point it is hard to spot
which of those is current.

Hope this helps

Helmut

Reply via email to