pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/wm/progman wm/progman: Fix macOS build, remove extrane...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/1dc5912ae366
branches:  trunk
changeset: 377199:1dc5912ae366
user:      sjmulder <sjmulder%pkgsrc.org@localhost>
date:      Sun Apr 17 21:16:12 2022 +0000

description:
wm/progman: Fix macOS build, remove extraneous quoting

 - macOS doesn't have pipe2(), replace with pipe()+fcntl().
 - pkglint said DESTDIR and PREFIX quoting is not required.

diffstat:

 wm/progman/Makefile                |   8 ++++----
 wm/progman/distinfo                |   3 ++-
 wm/progman/patches/patch-progman.c |  20 ++++++++++++++++++++
 3 files changed, 26 insertions(+), 5 deletions(-)

diffs (61 lines):

diff -r 1c1a591640fc -r 1dc5912ae366 wm/progman/Makefile
--- a/wm/progman/Makefile       Sun Apr 17 20:11:39 2022 +0000
+++ b/wm/progman/Makefile       Sun Apr 17 21:16:12 2022 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.2 2021/12/08 16:06:51 adam Exp $
+# $NetBSD: Makefile,v 1.3 2022/04/17 21:16:12 sjmulder Exp $
 
 DISTNAME=      progman-1.0
-PKGREVISION=   1
+PKGREVISION=   2
 CATEGORIES=    wm
 MASTER_SITES=  ${MASTER_SITE_GITHUB:=jcs/}
 GITHUB_TAG=    v${PKGVERSION_NOREV}
@@ -19,8 +19,8 @@
 CFLAGS+=       -DINFTIM=-1
 LDFLAGS+=      -lXext
 
-MAKE_FLAGS+=   PREFIX=${DESTDIR:Q}${PREFIX:Q}
-MAKE_FLAGS+=   MANDIR=${DESTDIR:Q}${PREFIX:Q}/${PKGMANDIR}/man1
+MAKE_FLAGS+=   PREFIX=${DESTDIR}${PREFIX}
+MAKE_FLAGS+=   MANDIR=${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
 
 .include "../../x11/libX11/buildlink3.mk"
 .include "../../x11/libXext/buildlink3.mk"
diff -r 1c1a591640fc -r 1dc5912ae366 wm/progman/distinfo
--- a/wm/progman/distinfo       Sun Apr 17 20:11:39 2022 +0000
+++ b/wm/progman/distinfo       Sun Apr 17 21:16:12 2022 +0000
@@ -1,7 +1,8 @@
-$NetBSD: distinfo,v 1.1 2021/11/19 18:59:09 sjmulder Exp $
+$NetBSD: distinfo,v 1.2 2022/04/17 21:16:12 sjmulder Exp $
 
 BLAKE2s (progman-1.0.tar.gz) = 2b10d1b755eda1883f4906dd0df5e95e8ef3c36df25f82dc0d7dc7a0d533a403
 SHA512 (progman-1.0.tar.gz) = bfc329277b39b500ae829a2e97e2c4d6058b2c6a8fdb2c453073c32b526c582c6e6a4632ec4df1f98ae3d7b072c8744370e1017f2bc5e757c9bd9f78e5add5dd
 Size (progman-1.0.tar.gz) = 44214 bytes
 SHA1 (patch-Makefile) = 4da84f934ed6a4f03b5a3a3eac1f0cfe2cc59a4d
+SHA1 (patch-progman.c) = 565d16797cbcb2a2be58ca880b0cb15760e2ffe2
 SHA1 (patch-progman.ini) = be2de652e956f5794be41afcc2041a4eb6f92da1
diff -r 1c1a591640fc -r 1dc5912ae366 wm/progman/patches/patch-progman.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/wm/progman/patches/patch-progman.c        Sun Apr 17 21:16:12 2022 +0000
@@ -0,0 +1,20 @@
+$NetBSD: patch-progman.c,v 1.1 2022/04/17 21:16:12 sjmulder Exp $
+
+Replace use of pipe2() for macOS compatibility.
+
+--- progman.c.orig     2022-04-17 21:02:47.000000000 +0000
++++ progman.c
+@@ -186,8 +186,11 @@ main(int argc, char **argv)
+ 
+       read_config();
+ 
+-      if (pipe2(exitmsg, O_CLOEXEC) != 0)
+-              err(1, "pipe2");
++      if (pipe(exitmsg) != 0)
++              err(1, "pipe");
++      if (fcntl(exitmsg[0], F_SETFD, FD_CLOEXEC) != 0 ||
++          fcntl(exitmsg[1], F_SETFD, FD_CLOEXEC) != 0)
++              err(1, "fcntl");
+ 
+       act.sa_handler = sig_handler;
+       act.sa_flags = 0;



Home | Main Index | Thread Index | Old Index