From: Richard Maw Date: Wed, 24 Apr 2024 13:44:27 +0000 (+0100) Subject: TEST-26-SYSTEMCTL: Create /etc/init.d if needed X-Git-Tag: v256-rc2~188^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4114b723f965ed19c8cf56be130a91f6abc99ea9;p=thirdparty%2Fsystemd.git TEST-26-SYSTEMCTL: Create /etc/init.d if needed OpenSUSE doesn't disable sysv compat but also may not have anything in /etc/init.d. --- diff --git a/test/units/testsuite-26.sh b/test/units/testsuite-26.sh index 6734aee654f..27aa98edb78 100755 --- a/test/units/testsuite-26.sh +++ b/test/units/testsuite-26.sh @@ -386,6 +386,10 @@ if [[ -x /usr/lib/systemd/system-generators/systemd-sysv-generator ]]; then # at runtime, so let's just support the two most common paths for now. [[ -d /etc/rc.d/init.d ]] && SYSVINIT_PATH="/etc/rc.d/init.d" || SYSVINIT_PATH="/etc/init.d" + # OpenSUSE leaves sysvinit-path enabled, which means systemd-sysv-generator is built + # but may not create the directory if there's no services that use it. + mkdir -p "$SYSVINIT_PATH" + # invalid dependency cat >"${SYSVINIT_PATH:?}/issue-24990" <<\EOF #!/bin/bash