From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [RFC v3 00/30] Add per-package staging feature
Date: Fri, 12 Jun 2015 22:14:56 +0200 [thread overview]
Message-ID: <20150612221456.44a97ad5@free-electrons.com> (raw)
In-Reply-To: <1425374255-6827-1-git-send-email-fabio.porcedda@gmail.com>
Dear Fabio Porcedda,
On Tue, 3 Mar 2015 10:17:05 +0100, Fabio Porcedda wrote:
> this patch set aims to improve build reproducibility by using a
> per-package staging directory.
> Also this feature aims to enable as default the top-level parallel make.
Here are some comments I wrote down a long time ago. It isn't a full
review, but it should give some initial thoughts:
If I understood correctly, the strategy used by your patches consists
in storing only the bare toolchain sysroot in output/staging/, and
using a per-package output/stagingpkg/<pkg>/ directory to store as an
input to the build the staging files needed to build the package, and
also as output the result of the build of the package.
I am not entirely happy with this solution, for the following reasons:
* We no longer have a single staging directory that has all the
libraries installed. This is needed for the toolchain to be a
proper SDK usable by application developers outside of Buildroot.
To solve this, either we install everything to both the real
STAGING_DIR and a per-package staging directory, or we create a
final build step that consolidates all the per-package staging
directories into a global one. The advantage of this second option
is that we don't have any parallel installation going on in the
global staging directory.
* I am not super happy with the idea of having the toolchain sysroot
left in the global staging directory and referenced by the compiler
--sysroot option on one side, and all other libraries found by
using -L, -I and pkg-config tricks.
I would actually prefer if a real complete sysroot was used when
building each package, and the compiler --sysroot option used to
adjust the compiler sysroot. This has however one significant
drawback: the toolchain sysroot must be copied for each and every
package, which can become quite time and space consuming. So on
this aspect, I'd like to have some input from other Buildroot
developers.
* Your patch uses $($(2)_ADD_TOOLCHAIN_DEPENDENCY) to decide whether
the per-package sysroot mechanism must be used or not. Which means
it will only be used for target packages, and not for host
packages. However, I'm wondering if we should not also apply the
principle to host packages: to get reproducible builds, I believe
we should also have separate sysroots when building host
packages. Opinions from other Buildroot developers?
* Your approach only takes care of make the sysroot handled in a
per-package fashion. But what about HOST_DIR ? We could have the
same inconsistencies as the ones we discussed about STAGING_DIR, but
this time caused by the presence/absence of host utilities. One
build may give a given result because host tool "foo" is present (it
happened to be built before), and the next build may give a
different result because host tool "foo" is absent (it's going to be
build after).
Now some more specific comments:
- The "enable parallel" patch should come last in the series.
- The patches "popt: add to the "popt.pc" file the libintl library"
and "logrotate: use pkg-config for the opt library" have been
merged in master, so you could get rid of them from your series.
- In patch "xinetd: use TARGET_LDFLAGS in order to support
per-package staging", why don't we simply use the LDFLAGS
environment variable, which seems to be understood by xinetd
Makefile? Also, missing SoB line.
- Patch "iproute2: use the TARGET_LDFLAGS variable" seems good to go,
if the commit log doesn't mention per-package sysroot, so that we
can merge it independently.
- Patch "opentyrian: use TARGET_LDFLAGS", having -lm before
$(TARGET_LDFLAGS) is probably more logical.
I didn't finished reviewing all of the package specific patches.
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
next prev parent reply other threads:[~2015-06-12 20:14 UTC|newest]
Thread overview: 59+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-03 9:17 [Buildroot] [RFC v3 00/30] Add per-package staging feature Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 01/30] rtmpdump: use TARGET_LDFLAGS instead of TARGET_CFLAGS for XLDFLAGS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 02/30] xinetd: use TARGET_LDFLAGS in order to support per-package staging Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 03/30] iproute2: use the TARGET_LDFLAGS variable Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 04/30] opentyrian: use TARGET_LDFLAGS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 05/30] pppd: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 06/30] openswan: set LDFLAGS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 07/30] exim: use TARGET_LDFLAGS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 08/30] fbv: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 09/30] cups: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 10/30] faifa: " Fabio Porcedda
2015-03-03 16:57 ` Baruch Siach
2015-03-08 15:14 ` Fabio Porcedda
2015-03-08 15:18 ` Baruch Siach
2015-03-08 15:30 ` Fabio Porcedda
2015-03-08 16:28 ` Baruch Siach
2015-03-03 9:17 ` [Buildroot] [RFC v3 11/30] iw: use TARGET_CONFIGURE_OPTS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 12/30] dhcpdump: use TARGET_CONFIGURE_OPTS in order to support PPS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 13/30] dtc: add add support for per-package staging directory Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 14/30] openssh: add support to the " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 15/30] mjpg-streamer: add support for " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 16/30] tcpreplay: delay the execution of pcap-config Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 17/30] erlang: add support for the per-package staging directory Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 18/30] perl: don't loose the -shared flag when TARGET_LDFLAGS isn't empty Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 19/30] erlang-p1-iconv: bump to a version that use TARGET_CFLAGS Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 20/30] erlang-p1-zlib: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 21/30] lmbench: to be checked Fabio Porcedda
2015-03-03 16:56 ` Baruch Siach
2015-03-08 14:53 ` Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 22/30] Makefile: add the STAGINGNOPKG_DIR variable Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 23/30] gpsd: add support for per-package staging directory Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 24/30] triggerhappy: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 25/30] ipsec-tools: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 26/30] pkg-cmake: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 27/30] pkg-luarocks: " Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 28/30] pkgconf: Move PKG_CONFIG_HOST_BINARY to Makefile.in Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 29/30] pkg-generic: ADD_TOOLCHAIN_DEPENDENCY is true only for target packages Fabio Porcedda
2015-03-03 9:17 ` [Buildroot] [RFC v3 30/30] pkg-generic: add support for per-package staging directory Fabio Porcedda
2015-03-06 0:28 ` Arnout Vandecappelle
2015-05-13 6:22 ` Fabio Porcedda
2015-03-03 13:29 ` [Buildroot] [RFC v3 00/30] Add per-package staging feature Thomas Petazzoni
2015-03-03 14:03 ` Fabio Porcedda
2015-03-03 14:21 ` Thomas Petazzoni
2015-03-11 17:29 ` Fabio Porcedda
2015-03-05 3:54 ` Jérôme Oufella
2015-03-05 8:14 ` Fabio Porcedda
2015-03-05 22:48 ` Arnout Vandecappelle
2015-03-14 16:15 ` Fabio Porcedda
2015-06-17 23:32 ` Arnout Vandecappelle
2015-06-28 15:51 ` Fabio Porcedda
2015-06-12 20:14 ` Thomas Petazzoni [this message]
2015-06-15 9:06 ` Fabio Porcedda
2015-06-15 9:17 ` Thomas Petazzoni
2015-06-17 23:09 ` Arnout Vandecappelle
2015-06-28 15:36 ` Fabio Porcedda
2015-06-28 18:13 ` Thomas Petazzoni
2015-06-28 15:33 ` Fabio Porcedda
2015-06-28 18:12 ` Thomas Petazzoni
2015-06-28 19:34 ` Fabio Porcedda
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150612221456.44a97ad5@free-electrons.com \
--to=thomas.petazzoni@free-electrons.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox