diff --git a/.gitignore b/.gitignore index d81bc08..e1e6bb7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /light-locker-1.6.0.tar.bz2 /light-locker-1.7.0.tar.bz2 +/light-locker-1.7.0.tar.gz diff --git a/light-locker-1.7.0-fix_detection_systemd.patch b/light-locker-1.7.0-fix_detection_systemd.patch new file mode 100644 index 0000000..3c1ffd7 --- /dev/null +++ b/light-locker-1.7.0-fix_detection_systemd.patch @@ -0,0 +1,38 @@ +From 97c2b936f9a5bbb91f3b26dbf899862bd38b8858 Mon Sep 17 00:00:00 2001 +From: Peter de Ridder +Date: Wed, 7 Jun 2017 20:08:07 +0200 +Subject: [PATCH] Updated configure for systemd > 209 and autotools + +--- + configure.ac.in | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/configure.ac.in b/configure.ac.in +index f7d5f5d..745c92d 100644 +--- a/configure.ac.in ++++ b/configure.ac.in +@@ -1,6 +1,7 @@ + dnl -*- mode: m4 -*- + + AC_PREREQ(2.60) ++LT_PREREQ([2.4]) + AC_INIT([light-locker], + [1.7.0]) + +@@ -18,7 +19,6 @@ AC_ISC_POSIX + AC_PROG_CC + AM_PROG_CC_C_O + AC_STDC_HEADERS +-AC_PROG_LIBTOOL + AC_CANONICAL_HOST + + AC_HEADER_STDC +@@ -424,7 +424,7 @@ AC_ARG_WITH(systemd, + [with_systemd=$withval], [with_systemd=auto]) + + PKG_CHECK_MODULES(SYSTEMD, +- [libsystemd-login], ++ [libsystemd], + [have_systemd=yes], [have_systemd=no]) + + if test "x$with_systemd" = "xauto" ; then diff --git a/light-locker.spec b/light-locker.spec index 804dc44..7a84a0f 100644 --- a/light-locker.spec +++ b/light-locker.spec @@ -1,14 +1,21 @@ Name: light-locker Version: 1.7.0 -Release: 3%{?dist} -Summary: A simple session-locker for lightdm +Release: 4%{?dist} +Summary: A simple session-locker for lightdm # unclear license: https://github.com/the-cavalry/light-locker/issues/33 License: GPLv2+ URL: https://github.com/the-cavalry/%{name} -Source0: %{url}/releases/download/v%{version}/%{name}-%{version}.tar.bz2 +Source0: %{url}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz -#BuildRequires: gtk2-devel +# Add upstream patch to fix detection of systemd. +# See: https://bugzilla.redhat.com/show_bug.cgi?id=1462463 +Patch0: %{url}/commit/97c2b936f9a5bbb91f3b26dbf899862bd38b8858.patch#/%{name}-1.7.0-fix_detection_systemd.patch + +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: libtool +BuildRequires: xfce4-dev-tools BuildRequires: gtk3-devel BuildRequires: libXScrnSaver-devel # xorg-x11-proto provides "mit-ext" @@ -31,43 +38,63 @@ It relies on lightdm for locking and unlocking your session. %prep -%setup -q +%autosetup -p 1 +NOCONFIGURE=1 ./autogen.sh + %build # FIXME build also gtk2? ( --with-gtk2 ) # enforce lock on suspend as RedHat Security Response Team requests (see rhbz#614608 and 632978) -%configure --enable-lock-on-suspend=on --disable-silent-rules --with-gtk3 -%make_build V=1 +%configure \ + --disable-silent-rules \ + --enable-lock-on-suspend=on \ + --with-gtk3 \ + --with-systemd \ + --without-console-kit +%make_build + %install %make_install %find_lang %{name} + %check desktop-file-validate %{buildroot}%{_sysconfdir}/xdg/autostart/*.desktop +%if (0%{?fedora} && 0%{?fedora} <= 23) || (0%{?rhel} && 0%{?rhel} <= 7) %postun if [ $1 -eq 0 ] ; then /usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || : fi +%endif + +%if (0%{?fedora} && 0%{?fedora} <= 23) || (0%{?rhel} && 0%{?rhel} <= 7) %posttrans - /usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || : +/usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || : +%endif %files -f %{name}.lang %license COPYING COPYING.LIB # ignore empty file HACKING -%doc AUTHORS ChangeLog NEWS README +#doc AUTHORS ChangeLog NEWS README +%doc AUTHORS NEWS README %{_bindir}/%{name}* - %{_sysconfdir}/xdg/autostart/*.desktop +%{_sysconfdir}/xdg/autostart/*.desktop # glib2 owns %{datadir}/glib-2.0/schemas %{_datadir}/glib-2.0/schemas/apps.*.xml %{_mandir}/man1/%{name}*.1* %changelog +* Sun Jun 18 2017 Björn Esser - 1.7.0-4 +- Add upstream patch to fix detection of systemd (rhbz#1462463) +- Update spec file to recent guidelines +- Use unmodified git-tree as souces, so patches can be applied easily + * Fri Feb 10 2017 Fedora Release Engineering - 1.7.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild diff --git a/sources b/sources index 3587a93..4bd1473 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -1683af64cff7f9ff460a1fb670e170e8 light-locker-1.7.0.tar.bz2 +SHA512 (light-locker-1.7.0.tar.gz) = 6202bee0012b9456aa034d3f172229c0a76501e5801149e7133f22853b516a40eb8ee9eb8d9795c2950febd8521e31a44d889515595799ff4ea285bc2cf983d5