|
@@ -3,24 +3,27 @@
|
|
|
Summary: PolicyKit Authorization Framework
|
|
|
Summary(ja): PolicyKit 認証フレームワーク
|
|
|
Name: polkit
|
|
|
-Version: 0.120
|
|
|
-Release: 2%{?_dist_release}%{?with_systemd:.systemd}
|
|
|
+Version: 124
|
|
|
+Release: 1%{?_dist_release}%{?with_systemd:.systemd}
|
|
|
Group: system
|
|
|
Vendor: Project Vine
|
|
|
Distribution: Vine Linux
|
|
|
|
|
|
License: LGPLv2+
|
|
|
URL: https://www.freedesktop.org/wiki/Software/polkit
|
|
|
-Source0: https://www.freedesktop.org/software/%{name}/releases/%{name}-%{version}.tar.gz
|
|
|
-Patch0: polkit-0.115-elogind.patch
|
|
|
-Patch1001: CVE-2021-4034.patch
|
|
|
-Patch1002: CVE-2021-4115.patch
|
|
|
+Source0: https://github.com/polkit-org/polkit/archive/refs/tags/%{version}.tar.gz
|
|
|
+Source1: polkit.sysusers
|
|
|
+Patch1: no-session-for-cookie.patch
|
|
|
+Patch2: pkttyagent-coredump-after-eof.patch
|
|
|
+Patch3: session-monitor-watch-sessions-only.patch
|
|
|
+Patch4: pkpermission-watch-changed-ssn-only.patch
|
|
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
|
|
+BuildRequires: meson
|
|
|
BuildRequires: glib2-devel
|
|
|
BuildRequires: expat-devel
|
|
|
BuildRequires: pam-devel
|
|
|
-BuildRequires: mozjs78-devel
|
|
|
+BuildRequires: duktape-devel
|
|
|
BuildRequires: gtk-doc
|
|
|
BuildRequires: intltool
|
|
|
BuildRequires: gobject-introspection-devel
|
|
@@ -77,50 +80,50 @@ Development documentation for PolicyKit.
|
|
|
|
|
|
|
|
|
%prep
|
|
|
-%setup -q
|
|
|
-%if !%{with systemd}
|
|
|
-%patch0 -p1
|
|
|
+%autosetup -p1
|
|
|
+
|
|
|
+%if %{without systemd}
|
|
|
+sed -i -e '/systemd_sysusers_dir = /d' meson.build
|
|
|
%endif
|
|
|
-%patch1001 -p1
|
|
|
-%patch1002 -p1
|
|
|
|
|
|
|
|
|
%build
|
|
|
-autoreconf -vif
|
|
|
-%configure \
|
|
|
- --with-os-type=redhat \
|
|
|
- --enable-gtk-doc \
|
|
|
- --disable-static \
|
|
|
- --libexecdir=%{_libexecdir}/polkit-1 \
|
|
|
- --enable-introspection \
|
|
|
+%meson \
|
|
|
+ -D authfw=pam \
|
|
|
+ -D examples=false \
|
|
|
+ -D gtk_doc=true \
|
|
|
+ -D introspection=true \
|
|
|
+ -D man=true \
|
|
|
%if %{with systemd}
|
|
|
- --enable-libsystemd-login=yes \
|
|
|
+ -D session_tracking=libsystemd-login \
|
|
|
%else
|
|
|
- --enable-libelogind=yes \
|
|
|
+ -D session_tracking=libelogind \
|
|
|
%endif
|
|
|
- --enable-examples
|
|
|
+ -D tests=false
|
|
|
|
|
|
-make %{?_smp_mflags}
|
|
|
+%meson_build
|
|
|
|
|
|
|
|
|
%install
|
|
|
-rm -rf $RPM_BUILD_ROOT
|
|
|
-make install DESTDIR=$RPM_BUILD_ROOT
|
|
|
+%meson_install
|
|
|
+%if %{with systemd}
|
|
|
+install -Dpm 0644 %{SOURCE1} %{buildroot}%{_sysusersdir}/polkit.conf
|
|
|
+%endif
|
|
|
|
|
|
-rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
|
|
|
-rm -f $RPM_BUILD_ROOT%{_libdir}/polkit-1/extensions/*.la
|
|
|
+mv -f %{buildroot}%{_prefix}/lib/pam.d %{buildroot}%{_sysconfdir}/
|
|
|
+rm -f %{buildroot}%{_libdir}/*.la
|
|
|
|
|
|
%find_lang polkit-1
|
|
|
|
|
|
|
|
|
-%clean
|
|
|
-rm -rf $RPM_BUILD_ROOT
|
|
|
-
|
|
|
-
|
|
|
%pre
|
|
|
+%if %{with systemd}
|
|
|
+%sysusers_create_compat %{SOURCE1}
|
|
|
+%else
|
|
|
groupadd -g 27 -r polkitd >/dev/null 2>&1 || :
|
|
|
useradd -u 27 -g polkitd -r -d '/' -s /sbin/nologin -c "User for polkitd" polkitd >/dev/null 2>&1 || :
|
|
|
exit 0
|
|
|
+%endif
|
|
|
|
|
|
%post
|
|
|
%if %{with systemd}
|
|
@@ -139,22 +142,23 @@ exit 0
|
|
|
|
|
|
|
|
|
%files -f polkit-1.lang
|
|
|
-%defattr(-,root,root,-)
|
|
|
%license COPYING
|
|
|
-%doc NEWS README
|
|
|
+%doc NEWS.md README.md
|
|
|
%{_libdir}/lib*.so.*
|
|
|
%{_datadir}/man/man1/*
|
|
|
%{_datadir}/man/man8/*
|
|
|
%{_datadir}/dbus-1/system-services/*
|
|
|
%if %{with systemd}
|
|
|
%{_unitdir}/polkit.service
|
|
|
+%{_sysusersdir}/polkit.conf
|
|
|
%endif
|
|
|
%dir %{_datadir}/polkit-1/
|
|
|
%dir %{_datadir}/polkit-1/actions
|
|
|
-%attr(0700,polkitd,root) %dir %{_datadir}/polkit-1/rules.d
|
|
|
%{_datadir}/polkit-1/actions/org.freedesktop.policykit.policy
|
|
|
+%attr(0700,polkitd,root) %dir %{_datadir}/polkit-1/rules.d
|
|
|
+%{_datadir}/polkit-1/rules.d/50-default.rules
|
|
|
+%{_datadir}/polkit-1/policyconfig-1.dtd
|
|
|
%dir %{_sysconfdir}/polkit-1
|
|
|
-%{_sysconfdir}/polkit-1/rules.d/50-default.rules
|
|
|
%attr(0700,polkitd,root) %dir %{_sysconfdir}/polkit-1/rules.d
|
|
|
%dir %{_datadir}/dbus-1
|
|
|
%dir %{_datadir}/dbus-1/system.d
|
|
@@ -172,23 +176,22 @@ exit 0
|
|
|
%attr(4755,root,root) %{_prefix}/lib/polkit-1/polkit-agent-helper-1
|
|
|
|
|
|
%files devel
|
|
|
-%defattr(-,root,root,-)
|
|
|
%{_libdir}/lib*.so
|
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
%{_datadir}/gir-1.0/*.gir
|
|
|
%{_includedir}/*
|
|
|
-%{_bindir}/pk-example-frobnicate
|
|
|
-%{_datadir}/polkit-1/actions/org.freedesktop.policykit.examples.pkexec.policy
|
|
|
%dir %{_datadir}/gettext
|
|
|
%dir %{_datadir}/gettext/its
|
|
|
%{_datadir}/gettext/its/*
|
|
|
|
|
|
%files docs
|
|
|
-%defattr(-,root,root,-)
|
|
|
%{_datadir}/gtk-doc/html/*
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
+* Thu Jul 18 2024 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 124-1
|
|
|
+- new upstream release.
|
|
|
+
|
|
|
* Sat Mar 05 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.120-2
|
|
|
- imported Patch1002 from upstream to fix CVE-2021-4115.
|
|
|
|