[build2] possible to do something similar to DESTDIR= make install?
boris at codesynthesis.com
Sun Aug 13 14:58:17 UTC 2017
Norbert Lange <nolange79 at gmail.com> writes:
> I just found out about build2 and would like to create a debian
> package for easy (un)installation.
Great. I will be glad to assist if you run into any other issues.
> I am hanging on the install step, normally you would so a fake-install
> and then archive the data.
> DESTDIR=/tmp/hugo make install
> would install an executable into /tmp/hugo/usr/bin
> To create (conforming) debian packages, both of build2 and software
> that uses build2 such a mechanism is needed.
> Might be that its already available, but I dint find any reference.
I've implemented this and it's now available in the staged version:
The new configuration variable is called config.install.chroot. Here is
the usage example:
b config.install.root=/usr config.install.chroot=/tmp/install install
> Another relevant point is, that for building (conforming) debian
> packages it is not allowed to access the net. This is possible for
> build2 itself, I am not sure its possible for packages using it?
Yes, sure. Every build2 package is a build2 project which means it
can be downloaded, built, and installed manually, without using the
bpkg package manager.
In fact, if I were to create Debian packages of the toolchain, I
wouldn't even use build2-toolchain. Instead I would first get
libbutl and build2 and bootstrap the build system (see the INSTALL
file inside build2/ for details). The result of this step will be
two Debian packages: libbutl and build2.
Then you can package libbpkg (which will use the build system and
depend on libbutl). This will result in the libbpkg Debian package.
Then you can package bpkg (which will use the build system and
depend on libbpkg and libbutl).
And that will get you the entire toolchain packaged.
More information about the users