mirror of
https://github.com/systemd/systemd.git
synced 2024-11-23 18:23:32 +08:00
test: mount ld.so.cache in minimal nspawn container if present
In some cases (SUSE Tumbleweed) this is needed as a library (libz) is
not in the default path, so it fails to run.
(cherry picked from commit 1e17e48b96
)
This commit is contained in:
parent
230f5613c9
commit
a2c84836ef
@ -969,6 +969,11 @@ testcase_check_os_release() {
|
||||
--bind-ro="$base/usr:/usr"
|
||||
)
|
||||
|
||||
# Might be needed to find libraries
|
||||
if [ -f "$base/etc/ld.so.cache" ]; then
|
||||
common_opts+=("--bind-ro=$base/etc/ld.so.cache:/etc/ld.so.cache")
|
||||
fi
|
||||
|
||||
# Empty /etc/ & /usr/
|
||||
(! systemd-nspawn "${common_opts[@]}")
|
||||
(! SYSTEMD_NSPAWN_CHECK_OS_RELEASE=1 systemd-nspawn "${common_opts[@]}")
|
||||
|
Loading…
Reference in New Issue
Block a user