]> git.pld-linux.org Git - packages/polkit.git/blobdiff - polkit.spec
temporarily switch to gitlab's tag as source; rel 2
[packages/polkit.git] / polkit.spec
index 5d7969a9922f9701af6c255a7c3c0cb15488abca..3eef9ed1eef36cf04964963a3161ee52940c1876 100644 (file)
@@ -1,46 +1,56 @@
 #
 # Conditional build:
 %bcond_without apidocs         # build without apidocs
-%bcond_without systemd         # use systemd for session tracking instead of ConsoleKit (fallback to ConsoleKit on runtime)
+%bcond_without consolekit      # ConsoleKit fallback
+%bcond_without systemd         # use systemd-login for session tracking (fallback to ConsoleKit on runtime)
+%bcond_with    elogind         # use elogind instead of systemd-login
 
+%if %{with elogind}
+%undefine      with_systemd
+%endif
 Summary:       A framework for defining policy for system-wide components
 Summary(pl.UTF-8):     Szkielet do definiowania polityki dla komponentów systemowych
 Name:          polkit
-Version:       0.113
-Release:       1
+Version:       0.119
+Release:       2
 License:       LGPL v2+
 Group:         Libraries
-Source0:       http://www.freedesktop.org/software/polkit/releases/%{name}-%{version}.tar.gz
-# Source0-md5: 4b77776c9e4f897dcfe03b2c34198edf
+Source0:       https://gitlab.freedesktop.org/polkit/polkit/-/archive/%{version}/%{name}-%{version}.tar.bz2
+# Source0-md5: 16b0ec658efae724378c7f75233d4120
 Patch0:                systemd-fallback.patch
-Patch1:                js187.patch
-URL:           http://www.freedesktop.org/wiki/Software/polkit
+URL:           https://www.freedesktop.org/wiki/Software/polkit
 BuildRequires: autoconf >= 2.60
 BuildRequires: automake >= 1:1.7
 BuildRequires: docbook-dtd412-xml
 BuildRequires: docbook-style-xsl
+%{?with_elogind:BuildRequires: elogind-devel}
 BuildRequires: expat-devel >= 1:1.95.8
 BuildRequires: gettext-tools
 BuildRequires: glib2-devel >= 1:2.32.0
+%if %(locale -a | grep -q '^C\.utf8$'; echo $?)
+BuildRequires: glibc-localedb-all
+%endif
 BuildRequires: gobject-introspection-devel >= 0.6.2
 %{?with_apidocs:BuildRequires: gtk-doc >= 1.3}
 BuildRequires: gtk-doc-automake >= 1.3
 BuildRequires: intltool >= 0.40.0
-BuildRequires: js187-devel
-BuildRequires: libtool
+BuildRequires: libstdc++-devel >= 6:4.7
+BuildRequires: libtool >= 2:1.5
 BuildRequires: libxslt-progs
+BuildRequires: mozjs78-devel
 BuildRequires: pam-devel >= 0.80
 BuildRequires: pkgconfig
 BuildRequires: python-modules
 BuildRequires: rpmbuild(macros) >= 1.647
 %{?with_systemd:BuildRequires: systemd-devel}
 Requires:      %{name}-libs = %{version}-%{release}
-%if %{without systemd}
+%if %{without systemd} && %{without elogind}
 Requires:      ConsoleKit >= 0.4.1
-%else
-Requires:      systemd-units >= 38
 %endif
 Requires:      dbus >= 1.1.2-5
+%if %{with systemd}
+Requires:      systemd-units >= 38
+%endif
 Obsoletes:     PolicyKit
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -58,6 +68,7 @@ Summary(pl.UTF-8):    Dokumentacja API PolicyKit
 Group:         Documentation
 Requires:      gtk-doc-common
 Obsoletes:     PolicyKit-apidocs
+BuildArch:     noarch
 
 %description apidocs
 PolicyKit API documentation.
@@ -110,8 +121,9 @@ Statyczne biblioteki PolicyKit.
 
 %prep
 %setup -q
-%{?with_systemd:%patch0 -p1}
-%patch1 -p1
+%if %{with consolekit} && (%{with systemd} || %{with elogind})
+%patch0 -p1
+%endif
 
 %build
 %{?with_apidocs:%{__gtkdocize}}
@@ -124,12 +136,15 @@ Statyczne biblioteki PolicyKit.
 %configure \
        %{__enable_disable apidocs gtk-doc} \
        --disable-silent-rules \
+       --disable-test \
+       %{__enable_disable elogind libelogind} \
        %{__enable_disable systemd libsystemd-login} \
        --with-html-dir=%{_gtkdocdir} \
        --with-pam-include=system-auth \
        --with-pam-module-dir=/%{_lib}/security \
        --with-polkitd-user=polkitd
 
+LC_ALL=C.UTF-8 \
 %{__make} -j1
 
 %install
@@ -175,12 +190,12 @@ fi
 %dir %{_sysconfdir}/polkit-1
 %attr(700,polkitd,root) %dir %{_sysconfdir}/polkit-1/rules.d
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/polkit-1/rules.d/50-default.rules
-/etc/dbus-1/system.d/org.freedesktop.PolicyKit1.conf
 /etc/pam.d/polkit-1
 %dir %{_datadir}/polkit-1
 %{_datadir}/polkit-1/actions
 %attr(700,polkitd,root) %dir %{_datadir}/polkit-1/rules.d
 %{_datadir}/dbus-1/system-services/org.freedesktop.PolicyKit1.service
+%{_datadir}/dbus-1/system.d/org.freedesktop.PolicyKit1.conf
 %{?with_systemd:%{systemdunitdir}/polkit.service}
 %{_mandir}/man1/pkaction.1*
 %{_mandir}/man1/pkcheck.1*
@@ -215,6 +230,8 @@ fi
 %{_pkgconfigdir}/polkit-gobject-1.pc
 %{_datadir}/gir-1.0/Polkit-1.0.gir
 %{_datadir}/gir-1.0/PolkitAgent-1.0.gir
+%{_datadir}/gettext/its/polkit.its
+%{_datadir}/gettext/its/polkit.loc
 
 %files static
 %defattr(644,root,root,755)
This page took 0.110418 seconds and 4 git commands to generate.