summaryrefslogtreecommitdiff
path: root/user/xautolock
diff options
context:
space:
mode:
authorDan Theisen <djt@hxx.in>2018-10-05 03:44:17 -0700
committerDan Theisen <djt@hxx.in>2018-10-05 03:44:17 -0700
commit88769bde43f35d5aa3b9443e63937d0e0e347101 (patch)
tree9fced54bc8c6f8fe9733f50492b5e7fbe9d71c87 /user/xautolock
parentc99a79ba9c222be7289efc6b5233e8fe170d9b17 (diff)
downloadpackages-88769bde43f35d5aa3b9443e63937d0e0e347101.tar.gz
packages-88769bde43f35d5aa3b9443e63937d0e0e347101.tar.bz2
packages-88769bde43f35d5aa3b9443e63937d0e0e347101.tar.xz
packages-88769bde43f35d5aa3b9443e63937d0e0e347101.zip
user/xautolock: new package
Diffstat (limited to 'user/xautolock')
-rw-r--r--user/xautolock/APKBUILD30
-rw-r--r--user/xautolock/processwait.patch33
2 files changed, 63 insertions, 0 deletions
diff --git a/user/xautolock/APKBUILD b/user/xautolock/APKBUILD
new file mode 100644
index 000000000..71fd17994
--- /dev/null
+++ b/user/xautolock/APKBUILD
@@ -0,0 +1,30 @@
+# Contributor: Johannes Matheis <jomat+alpinebuild@jmt.gr>
+# Maintainer: Dan Theisen <djt@hxx.in>
+pkgname=xautolock
+pkgver=2.2
+pkgrel=4
+pkgdesc="An automatic X screen-locker/screen-saver"
+url="http://ibiblio.org/pub/Linux/X11/screensavers/"
+arch="all" # this might not build on aarch64? removed from alpine commit
+license="GPL-2.0"
+options="!check" # This package has no testsuite
+depends=""
+makedepends="$depends_dev imake xorg-server-dev libxscrnsaver-dev xorg-cf-files"
+subpackages="$pkgname-doc"
+source="https://www.ibiblio.org/pub/linux/X11/screensavers/xautolock-$pkgver.tgz
+ processwait.patch"
+
+build() {
+ cd "$builddir"
+ xmkmf
+ make
+}
+
+package() {
+ cd "$builddir"
+ make DESTDIR="$pkgdir" install
+ make MANPATH=/usr/share/man DESTDIR="$pkgdir" install.man
+}
+
+sha512sums="5f9dcc25cda706610e77a74235c4b421ca3a833d154b1a269057f0774579e1c6ec36fe0e5be5fadd6942ce8c1640a760f891397586b162e6024b524635153d04 xautolock-2.2.tgz
+3242d01e394f8b84946d7d7fca9a87f2e17783352e180e43470737d3a2e4a7eb15f1a514dcd98118b6491895ab56d3cef29d4abb32b5a341c73efaa2a7ff323a processwait.patch"
diff --git a/user/xautolock/processwait.patch b/user/xautolock/processwait.patch
new file mode 100644
index 000000000..cb49f8d88
--- /dev/null
+++ b/user/xautolock/processwait.patch
@@ -0,0 +1,33 @@
+--- xautolock/src/engine.c.orig 2014-08-28 12:50:56.086307943 +0000
++++ xautolock/src/engine.c 2014-08-28 12:50:59.496333650 +0000
+@@ -209,24 +209,24 @@ evaluateTriggers (Display* d)
+ {
+ #else /* VMS */
+ if (lockerPid)
+ {
+-#if !defined (UTEKV) && !defined (SYSV) && !defined (SVR4)
++#if (!defined (UTEKV) && !defined (SYSV) && !defined (SVR4)) && defined (__GLIBC__)
+ union wait status; /* childs process status */
+-#else /* !UTEKV && !SYSV && !SVR4 */
++#else /* (!UTEKV && !SYSV && !SVR4) && __GLIBC__ */
+ int status = 0; /* childs process status */
+-#endif /* !UTEKV && !SYSV && !SVR4 */
++#endif /* (!UTEKV && !SYSV && !SVR4) && __GLIBC__ */
+
+ if (unlockNow && !disabled)
+ {
+ (void) kill (lockerPid, SIGTERM);
+ }
+
+-#if !defined (UTEKV) && !defined (SYSV) && !defined (SVR4)
++#if (!defined (UTEKV) && !defined (SYSV) && !defined (SVR4)) && defined (__GLIBC__)
+ if (wait3 (&status, WNOHANG, 0))
+-#else /* !UTEKV && !SYSV && !SVR4 */
++#else /* (!UTEKV && !SYSV && !SVR4) && __GLIBC__ */
+ if (waitpid (-1, &status, WNOHANG))
+-#endif /* !UTEKV && !SYSV && !SVR4 */
++#endif /* (!UTEKV && !SYSV && !SVR4) && __GLIBC__ */
+ {
+ /*
+ * If the locker exited normally, we disable any pending kill
+ * trigger. Otherwise, we assume that it either has crashed or