Commit Graph

9 Commits

Author SHA1 Message Date
Felix Fietkau 3fd070e089 tools/fakeroot: fix build regression on macOS
AT_EMPTY_PATH and AT_NO_AUTOMOUNT does not exist there

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-01-14 14:01:57 +01:00
Syrone Wong f34f4a6665 tools/fakeroot: update to 1.25.3
use PKG_FIXUP:=autoreconf to generate configure
200-hide-dlsym-error.patch deleted due to fixed upstream in another way
other patches refreshed to reflect latest changes

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2021-01-05 08:59:31 -10:00
Sven Wegener c5d033a34d tools/fakeroot: remove undefined symbol messages
glibc started to return errors from dlerror() for dlsym() lookup failures which
results in a lot of messages from fakeroot like

dlsym(acl_get_fd): staging_dir/host/lib/libfakeroot.so: undefined symbol: acl_get_fd
dlsym(acl_get_file): staging_dir/host/lib/libfakeroot.so: undefined symbol: acl_get_file
dlsym(acl_set_fd): staging_dir/host/lib/libfakeroot.so: undefined symbol: acl_set_fd

when building OpenWrt using a recent glibc. Use the patch from the upstream
Debian package to silence these messages.

Link: https://bugs.debian.org/830912
Fixes: FS#3393
Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
2020-12-31 12:09:09 -10:00
Felix Fietkau 0fd214d89f tools/fakeroot: fix build on macOS with recent Xcode versions
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2020-11-14 14:48:30 +01:00
Jo-Philipp Wich d4521fb132 tools: fakeroot: rework relocatable patch to avoid LD_LIBRARY_PATH usage
Due to the use of LD_LIBRARY_PATH, the programs running in the fakeroot
environment may end up loading bundled SDK libraries using the system
ld.so.

Rework the relocatability patch to avoid meddling with LD_LIBRARY_PATH
and construct the paths to faked and libfakeroot.so directly.

Fixes: f93cb5c2c8 ("fakeroot: make fakeroot script relocatable")
Reviewed-by: Petr Štetiar <ynezz@true.cz>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-11-10 08:31:10 +01:00
Jo-Philipp Wich f93cb5c2c8 fakeroot: make fakeroot script relocatable
Patch the fakeroot script template to discover faked and libfakeroot.so
relative to the STAGING_DIR_HOST environment variable, similar to how it
is done for automake, libtool, quilt and autoconf already.

This avoids the need for passing the paths to faked and libfakeroot.so
manually every time we invoke fakeroot and subsequently allows us to
drop OS X specific logic.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-10-30 00:39:09 +00:00
Jo-Philipp Wich 6485f521c9 tools: fakeroot: use TCP as IPC transport
Some environments, e.g. first gen WSL, do not support SysV IPC.
Enforce the use of TCP transport instead which should be universally
available.

Fixes: FS#3317
Ref: https://github.com/microsoft/WSL/issues/4067
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-09-09 13:33:50 +02:00
Daniel Golle 97096531bb fakeroot: add license information
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2020-09-08 15:02:52 +01:00
Thomas Petazzoni 9e7ef46065 tools: add fakeroot
SELinux support requires setting the appropriate SELinux security context
to files and directories, which needs to happen at build time in order
to support read-only root filesystem scenarios. In order to create these
security contexts, we will have to run some SELinux-specific tools on
the host machine, but that requires root access. This adds support for
fakeroot, which the build process will use to run the SELinux security
context creation and the image creation.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>

Apply to current master, and adjust commit message

Thomas' original work is available at
http://lists.infradead.org/pipermail/openwrt-devel/2019-November/025976.html.

Signed-off-by: W. Michael Petullo <mike@flyn.org>
[add rules.mk FAKEROOT variable]
Signed-off-by: Paul Spooren <mail@aparcar.org>
[update, fix macos build]
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2020-08-10 10:09:55 +02:00