<feed xmlns='http://www.w3.org/2005/Atom'>
<title>buildroot/fs/common.mk, branch 2017.11.2</title>
<subtitle>OpenPOWER buildroot sources</subtitle>
<id>https://git.raptorcs.com/git/buildroot/atom?h=2017.11.2</id>
<link rel='self' href='https://git.raptorcs.com/git/buildroot/atom?h=2017.11.2'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/'/>
<updated>2017-11-05T16:52:27+00:00</updated>
<entry>
<title>fs: add missing $$(sep) to pre- and post-command hooks code</title>
<updated>2017-11-05T16:52:27+00:00</updated>
<author>
<name>Andrey Smirnov</name>
<email>andrew.smirnov@gmail.com</email>
</author>
<published>2017-11-03T18:49:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=3f9476df07200fd86d59fb19b4183dafed5934f8'/>
<id>urn:sha1:3f9476df07200fd86d59fb19b4183dafed5934f8</id>
<content type='text'>
When multiple hooks are registred, both pre-a and post-command hooks'
foreach loops need to have a separator at the end in order for the
code to work as intended. Without the separator all hooks end up as a
one single line command thus making all but the first hook into
no-ops.

Fixes: 4628b6f3b4 ("fs: add pre- and post-command hooks")
Cc: Yann E. MORIN &lt;yann.morin.1998@free.fr&gt;
Cc: Romain Naour &lt;romain.naour@gmail.com&gt;
Signed-off-by: Andrey Smirnov &lt;andrew.smirnov@gmail.com&gt;
Acked-by: "Yann E. MORIN" &lt;yann.morin.1998@free.fr&gt;
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
</content>
</entry>
<entry>
<title>fs: add pre- and post-command hooks</title>
<updated>2017-08-02T18:58:27+00:00</updated>
<author>
<name>Yann E. MORIN</name>
<email>yann.morin.1998@free.fr</email>
</author>
<published>2017-08-01T22:52:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=4628b6f3b4512ec7cfb3c08ad4fe0ec40e1c5cc1'/>
<id>urn:sha1:4628b6f3b4512ec7cfb3c08ad4fe0ec40e1c5cc1</id>
<content type='text'>
In some cases, the directory structure we want in the filesystem is not
exactly what we have in target/

For example, when systemd is used on a read-only rootfs, /var must be a
tmpfs. However, we may have packages that install stuff in there, and
set important rights (via the permission-table). So, at build time, we
need /var to be a symlink to the remanent location (/usr/share/factory)
while at runtime we need /var to be a directory.

One option would have been to have /var as a real directory even during
build time, and in a target-finalize hook, move everything out of there
and into the "factory" location. However, that's not possible because
it's too early: some packages may want to set ownership and/or acces
rights on directories or files in /var, and this is only done in the
fakeroot script, which is called only later during the assembling of the
filesystem images.

Also, there would have been no way to undo the tweak (i.e. we need to
restore the /var symlink so that subsequent builds continue to work) if
it were done as a target-finalize hook.

The only solution is to allow packages to register pre- and post-hooks
that are called right before and right after the rootfs commands are
executed, and inside in the fakeroot script.

We can however not re-use the BR2_ROOTFS_POST_FAKEROOT_SCRIPT feature
either because it is done before the filesystem command, but there is
nothing that is done after. Also, we don't want to add to, and modify a
user-supplied variable.

So, we introduce two new variables that packages can set to add the
commands they need to run to tweak the filesystem right at the last
moment.

Those hooks are not documented on-purpose; they are probably going to
only ever be used by systemd.

Signed-off-by: "Yann E. MORIN" &lt;yann.morin.1998@free.fr&gt;
Reviewed-by: Romain Naour &lt;romain.naour@gmail.com&gt;
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>Globally replace $(HOST_DIR)/usr/bin with $(HOST_DIR)/bin</title>
<updated>2017-07-05T13:19:29+00:00</updated>
<author>
<name>Arnout Vandecappelle</name>
<email>arnout@mind.be</email>
</author>
<published>2017-07-05T11:14:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=0f9c0bf3d5cdd2f99b66da7ab7e23c7b2bfb8c69'/>
<id>urn:sha1:0f9c0bf3d5cdd2f99b66da7ab7e23c7b2bfb8c69</id>
<content type='text'>
Since things are no longer installed in $(HOST_DIR)/usr, the callers
should also not refer to it.

This is a mechanical change with
git grep -l '$(HOST_DIR)/usr/bin' | xargs sed -i 's%$(HOST_DIR)/usr/bin%$(HOST_DIR)/bin%g'

Signed-off-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>fs: set packages permissions even with no system device tables</title>
<updated>2016-12-14T22:45:48+00:00</updated>
<author>
<name>Yann E. MORIN</name>
<email>yann.morin.1998@free.fr</email>
</author>
<published>2016-12-14T22:28:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=5b272e3e551e723bae78140f7de4029b9026d961'/>
<id>urn:sha1:5b272e3e551e723bae78140f7de4029b9026d961</id>
<content type='text'>
Currently, when there is no syztem device table (permissions or static
devices) defined, then package permissions are not applied, because they
are guarded by the check on the system device tables being non empty.

Fix that by narrowing the guarding condition.

Note that the dependency on host-makedevs was not conditional; we always
build it even if we don't need it. Making it conditional is not
possible, because we don't know all the packages permissions by the time
the fs infra is parsed (packages from br2-external are parsed after it).

Signed-off-by: "Yann E. MORIN" &lt;yann.morin.1998@free.fr&gt;
Cc: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
Cc: Peter Korsgaard &lt;peter@korsgaard.com&gt;
Signed-off-by: Peter Korsgaard &lt;peter@korsgaard.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'next'</title>
<updated>2016-12-01T21:29:56+00:00</updated>
<author>
<name>Peter Korsgaard</name>
<email>peter@korsgaard.com</email>
</author>
<published>2016-12-01T21:22:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=8852f08eeda3c9ff4c5f9cc90a169338bda1bff9'/>
<id>urn:sha1:8852f08eeda3c9ff4c5f9cc90a169338bda1bff9</id>
<content type='text'>
Signed-off-by: Peter Korsgaard &lt;peter@korsgaard.com&gt;
</content>
</entry>
<entry>
<title>Revert "fs: use pseudo instead of fakeroot"</title>
<updated>2016-11-27T20:24:10+00:00</updated>
<author>
<name>Peter Korsgaard</name>
<email>peter@korsgaard.com</email>
</author>
<published>2016-11-27T20:13:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=79061fe52f9cf5925f603d938feddfe41aab340e'/>
<id>urn:sha1:79061fe52f9cf5925f603d938feddfe41aab340e</id>
<content type='text'>
This reverts commit 8035ceb56cc3ba2541aba0d0ead3f29900d9e310.

Moving to pseudo brought a number of issues (and longer compilation time),
so lets stick with fakeroot now that the reported ubi issue has been worked
around.

Signed-off-by: Peter Korsgaard &lt;peter@korsgaard.com&gt;
</content>
</entry>
<entry>
<title>Revert "fs: call the pseudo wrapper"</title>
<updated>2016-11-27T20:12:23+00:00</updated>
<author>
<name>Peter Korsgaard</name>
<email>peter@korsgaard.com</email>
</author>
<published>2016-11-27T20:11:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=9b2f9b137ce14bbca01f18c3a4357bd3219a6b9f'/>
<id>urn:sha1:9b2f9b137ce14bbca01f18c3a4357bd3219a6b9f</id>
<content type='text'>
This reverts commit 74a3e75bb8208a8f3bb8426549fce1ea09b3be8a.

Signed-off-by: Peter Korsgaard &lt;peter@korsgaard.com&gt;
</content>
</entry>
<entry>
<title>fs/common: lock modification times in $TARGET_DIR</title>
<updated>2016-11-23T21:59:21+00:00</updated>
<author>
<name>Jérôme Pouiller</name>
<email>jezz@sysmic.org</email>
</author>
<published>2016-11-23T12:58:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=68db7210fd8e76120c27cdc4a1fe591de67c06c2'/>
<id>urn:sha1:68db7210fd8e76120c27cdc4a1fe591de67c06c2</id>
<content type='text'>
Make sure all files in $TARGET_DIR have a defined modification time
before to generate filesystems.

This work was sponsored by `BA Robotic Systems'.

Signed-off-by: Jérôme Pouiller &lt;jezz@sysmic.org&gt;
Reviewed-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>fs: call the pseudo wrapper</title>
<updated>2016-11-09T22:30:07+00:00</updated>
<author>
<name>Yann E. MORIN</name>
<email>yann.morin.1998@free.fr</email>
</author>
<published>2016-11-08T22:18:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=74a3e75bb8208a8f3bb8426549fce1ea09b3be8a'/>
<id>urn:sha1:74a3e75bb8208a8f3bb8426549fce1ea09b3be8a</id>
<content type='text'>
Signed-off-by: "Yann E. MORIN" &lt;yann.morin.1998@free.fr&gt;
Cc: Gaël PORTAY &lt;gael.portay@savoirfairelinux.com&gt;
Cc: Patrick Keroulas &lt;patrick.keroulas@savoirfairelinux.com&gt;
Cc: Erico Nunes &lt;nunes.erico@gmail.com&gt;
Cc: Julien BOIBESSOT &lt;julien.boibessot@free.fr&gt;
Cc: Arnout Vandecappelle &lt;arnout@mind.be&gt;
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>fs: use pseudo instead of fakeroot</title>
<updated>2016-11-03T20:36:15+00:00</updated>
<author>
<name>Yann E. MORIN</name>
<email>yann.morin.1998@free.fr</email>
</author>
<published>2016-10-29T08:26:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=8035ceb56cc3ba2541aba0d0ead3f29900d9e310'/>
<id>urn:sha1:8035ceb56cc3ba2541aba0d0ead3f29900d9e310</id>
<content type='text'>
fakeroot misbhaves when there are SElinux contexts, as reported in #9386,
and further detailed in https://bugzilla.redhat.com/show_bug.cgi?id=1238802

A proposal in the FC bug is to use pseudo instead of fakeroot. Pseudo is
a from-scratch re-implementation of fakeroot; it is used in Poky/OE
instead of fakeroot.

Fixes #9386.

Reported-by: Andrey Yurovsky &lt;yurovsky@gmail.com&gt;
Signed-off-by: "Yann E. MORIN" &lt;yann.morin.1998@free.fr&gt;
Cc: Andrey Yurovsky &lt;yurovsky@gmail.com&gt;
Cc: Gustavo Zacarias &lt;gustavo@zacarias.com.ar&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
</feed>
