Auto-requies on binaries used in systemd .service files added
This commit is contained in:
parent
9c18a40269
commit
54a2ca259c
@ -961,6 +961,7 @@ AC_OUTPUT([ Doxyfile Makefile rpmrc macros platform rpmpopt
|
||||
scripts/shell.req
|
||||
scripts/static.req
|
||||
scripts/symlinks.req
|
||||
scripts/systemd-services.req
|
||||
scripts/verify-elf
|
||||
scripts/posttrans-filetriggers
|
||||
doc/Makefile doc/manual/Makefile
|
||||
|
@ -509,6 +509,7 @@ mv -T %buildroot%_rpmlibdir/{,build}macros
|
||||
%rpmattr %_rpmlibdir/static.*
|
||||
%rpmattr %_rpmlibdir/suggest_bpp
|
||||
%rpmattr %_rpmlibdir/symlinks.*
|
||||
%rpmattr %_rpmlibdir/systemd-services.*
|
||||
%rpmattr %_rpmlibdir/tmpdir.sh
|
||||
%rpmattr %_rpmlibdir/verify-elf
|
||||
%rpmattr %_rpmlibdir/*.awk
|
||||
|
@ -30,6 +30,7 @@ EXTRA_DIST = \
|
||||
shell.req shell.req.files shell.prov shell.prov.files \
|
||||
static.req static.req.files \
|
||||
symlinks.req symlinks.req.files \
|
||||
systemd-services.req systemd-services.req.files \
|
||||
tmpdir.sh \
|
||||
verify-elf
|
||||
|
||||
@ -62,6 +63,7 @@ config_SCRIPTS = \
|
||||
shell.req shell.req.files shell.prov shell.prov.files \
|
||||
static.req static.req.files \
|
||||
symlinks.req symlinks.req.files \
|
||||
systemd-services.req systemd-services.req.files \
|
||||
tmpdir.sh \
|
||||
verify-elf \
|
||||
# 0ldconfig.filetrigger find-package functions posttrans-filetriggers
|
||||
|
11
scripts/systemd-services.req.files
Executable file
11
scripts/systemd-services.req.files
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh -efu
|
||||
while IFS=$'\t' read -r f t; do
|
||||
case "$f" in
|
||||
${RPM_BUILD_ROOT-}/lib/systemd/system/*) ;;
|
||||
*) continue ;;
|
||||
esac
|
||||
case "$t" in
|
||||
*'symbolic link to '*) ;;
|
||||
*) echo "$f" ;;
|
||||
esac
|
||||
done
|
17
scripts/systemd-services.req.in
Executable file
17
scripts/systemd-services.req.in
Executable file
@ -0,0 +1,17 @@
|
||||
#!/bin/sh -efu
|
||||
|
||||
. @RPMCONFIGDIR@/functions
|
||||
. @RPMCONFIGDIR@/find-package
|
||||
|
||||
SystemdServiceReq()
|
||||
{
|
||||
local bin
|
||||
|
||||
grep -h '^[[:space:]]*Exec[^=]*=[^-]' "$1" |
|
||||
sed -n 's|^[[:space:]]*Exec[^=]*=[^/]*\(/[^[:space:]]\+\).*|\1|p' |
|
||||
while read bin; do
|
||||
FindPackage "$1" "$bin"
|
||||
done
|
||||
}
|
||||
|
||||
ArgvFileAction SystemdServiceReq "$@"
|
Loading…
Reference in New Issue
Block a user