From 8487e61b6af0a6bfc7a19e8c0cc6f301c8a5848a Mon Sep 17 00:00:00 2001 From: Toshaan Bharvani Date: Thu, 28 Dec 2023 16:14:04 +0100 Subject: [PATCH] initial package creation Signed-off-by: Toshaan Bharvani --- SOURCES/xautolock-longer-times.patch | 22 +++++++++++++ SPECS/xautolock.spec | 48 ++++++++++++++++++++++++++++ 2 files changed, 70 insertions(+) create mode 100644 SOURCES/xautolock-longer-times.patch create mode 100644 SPECS/xautolock.spec diff --git a/SOURCES/xautolock-longer-times.patch b/SOURCES/xautolock-longer-times.patch new file mode 100644 index 0000000..e9c2263 --- /dev/null +++ b/SOURCES/xautolock-longer-times.patch @@ -0,0 +1,22 @@ +diff -u -r -U5 xautolock-2.2/include/config.h xautolock-2.2.longer-times/include/config.h +--- xautolock-2.2/include/config.h 2007-09-30 17:27:49.000000000 -0400 ++++ xautolock-2.2.longer-times/include/config.h 2013-06-09 23:54:49.201065251 -0400 +@@ -75,16 +75,16 @@ + #define BELL_PERCENT 40 /* as is says */ + + #define MIN_LOCK_MINS 1 /* minimum number of minutes + before firing up the locker */ + #define LOCK_MINS 10 /* default ... */ +-#define MAX_LOCK_MINS 60 /* maximum ... */ ++#define MAX_LOCK_MINS 1440 /* maximum ... */ + + #define MIN_KILL_MINS 10 /* minimum number of minutes + before firing up the killer */ + #define KILL_MINS 20 /* default ... */ +-#define MAX_KILL_MINS 120 /* maximum ... */ ++#define MAX_KILL_MINS 1440 /* maximum ... */ + + #define CREATION_DELAY 30 /* should be > 10 and + < min(45,(MIN_LOCK_MINS*30)) */ + #define CORNER_SIZE 10 /* size in pixels of the + force-lock areas */ diff --git a/SPECS/xautolock.spec b/SPECS/xautolock.spec new file mode 100644 index 0000000..d15334e --- /dev/null +++ b/SPECS/xautolock.spec @@ -0,0 +1,48 @@ +Name: xautolock +Version: 2.2 +Release: 1%{?dist} +Summary: Launches a program when your X session has been idle +License: GPLv2 +URL: http://freshmeat.net/projects/xautolock/ +Source0: http://www.ibiblio.org/pub/Linux/X11/screensavers/%{name}-%{version}.tgz +Patch0: xautolock-2.2-XSS-fix.patch +# All of Debian's patches look pretty sane, so let's swipe 'em +# All by Roland Stigge, except 14 by Aurelien Jarno +Patch1: https://sources.debian.org/data/main/x/xautolock/1:2.2-5.1/debian/patches/10-fix-memory-corruption.patch +Patch2: https://sources.debian.org/data/main/x/xautolock/1:2.2-5.1/debian/patches/11-fix-no-dpms.patch +Patch3: https://sources.debian.org/data/main/x/xautolock/1:2.2-5.1/debian/patches/12-fix-manpage.patch +Patch4: https://sources.debian.org/data/main/x/xautolock/1:2.2-5.1/debian/patches/13-fix-hppa-build.patch +Patch5: https://sources.debian.org/data/main/x/xautolock/1:2.2-5.1/debian/patches/14-do-not-use-union-wait-type.patch +# See RHBZ#956271. Local change; worth upstreaming? +Patch100: xautolock-longer-times.patch +BuildRequires: make +BuildRequires: gcc +BuildRequires: imake +BuildRequires: libXScrnSaver-devel + + +%description +A program that launches a given program when +your X session has been idle for a given time. + + +%prep +%autosetup -p1 +xmkmf + + +%build +make %{?_smp_mflags} CDEBUGFLAGS="%{optflags}" CC="%{__cc}" + + +%install +make install install.man DESTDIR=%{buildroot} INSTALL="install -p" + + +%files +%doc Changelog License Readme Todo +%{_bindir}/xautolock +%{_mandir}/man1/xautolock.1* + + +%changelog