From be4317e8bfbd70f493b9e7069a5eae6eb1ceb9ff Mon Sep 17 00:00:00 2001 From: Zbigniew Jędrzejewski-Szmek Date: Apr 01 2020 21:39:32 +0000 Subject: Fix some rpmlint issues and add filter for others --- diff --git a/split-files.py b/split-files.py index d663b61..f3e3aa6 100644 --- a/split-files.py +++ b/split-files.py @@ -43,6 +43,7 @@ for file in files(buildroot): /etc(/pam\.d|/xdg|/X11|/X11/xinit|/X11.*\.d|)$| /etc/(dnf|dnf/protected.d)$| /usr/(src|lib/debug)| # no $ + /run$| /var(/cache|/log|/lib|/run|)$ ''', n, re.X): continue diff --git a/systemd.rpmlintrc b/systemd.rpmlintrc new file mode 100644 index 0000000..6bb8cb0 --- /dev/null +++ b/systemd.rpmlintrc @@ -0,0 +1,50 @@ +# Just kill all warnings about README being wrong in every possible way +addFilter(r'README') + +addFilter(r'missing-call-to-(chdir-with-chroot|setgroups-before-setuid)') + +addFilter(r'executable-marked-as-config-file /etc/X11/xinit/xinitrc.d/50-systemd-user.sh') + +addFilter(r'non-readable /etc/crypttab') + +addFilter(r'non-conffile-in-etc /etc/inittab') + +addFilter(r'systemd-unit-in-etc /etc/systemd/.*\.wants') + +addFilter(r'dangling-relative-symlink /usr/lib/environment.d/99-environment.conf ../../../etc/environment') + +addFilter(r'devel-file-in-non-devel-package /usr/share/pkgconfig/(systemd|udev).pc') + +addFilter(r'non-standard-dir-perm /var/cache/private 700') + +addFilter(r'non-root-group-log-file /var/log/btmp utmp') + +addFilter(r'non-standard-dir-perm /var/log/private 700') + +addFilter(r'non-root-group-log-file /var/log/wtmp utmp') + +addFilter(r'dangerous-command-in-') + +addFilter(r'summary-not-capitalized C systemd') + +addFilter(r'obsolete-not-provided') + +addFilter(r'postin-without-ldconfig') + +addFilter(r'systemd-rpm-macros.noarch: W: only-non-binary-in-usr-lib') + +addFilter(r'systemd-rpm-macros.noarch: W: no-documentation') + +addFilter(r'systemd-tests\..*: W: no-documentation') + +addFilter(r'systemd-tests.*: E: zero-length /usr/lib/systemd/tests/testdata/test-umount/empty.mountinfo') + +addFilter(r'hardcoded-library-path in.*(firewalld|install.d)') + +# everybody does it this way: systemd, syslog-ng, rsyslog +addFilter(r'unversioned-explicit-provides syslog') + +# systemd-machine-id-setup requires libssl +addFilter(r'explicit-lib-dependency openssl-libs') + +addFilter(r'systemd.src:.*strange-permission') diff --git a/systemd.spec b/systemd.spec index 121840e..18f027e 100644 --- a/systemd.spec +++ b/systemd.spec @@ -394,9 +394,9 @@ mkdir -p %{buildroot}%{system_unit_dir}/basic.target.wants mkdir -p %{buildroot}%{system_unit_dir}/default.target.wants mkdir -p %{buildroot}%{system_unit_dir}/dbus.target.wants mkdir -p %{buildroot}%{system_unit_dir}/syslog.target.wants -mkdir -p %{buildroot}%{_localstatedir}/run +mkdir -p %{buildroot}/run mkdir -p %{buildroot}%{_localstatedir}/log -touch %{buildroot}%{_localstatedir}/run/utmp +touch %{buildroot}/run/utmp touch %{buildroot}%{_localstatedir}/log/{w,b}tmp # Make sure the user generators dir exists too @@ -481,7 +481,7 @@ python3 %{SOURCE2} %buildroot < - 239-9.git9f3aed1 -- Go back to using systemctl preset-all in %post (#1647172, #1118740) +- Go back to using systemctl preset-all in %%post (#1647172, #1118740) * Mon Nov 5 2018 Adam Williamson - 239-8.git9f3aed1 - Requires(post) openssl-libs to fix live image build machine-id issue