View | Details | Raw Unified | Return to bug 205039 | Differences between
and this patch

Collapse All | Expand All

(-)sysutils/pesign/Makefile (-6 / +3 lines)
Lines 23-34 GH_ACCOUNT= rhinstaller Link Here
23
USES=		gmake pkgconfig
23
USES=		gmake pkgconfig
24
USE_LDCONFIG=	yes
24
USE_LDCONFIG=	yes
25
25
26
.include <bsd.port.pre.mk>
26
EXTRA_PATCHES=	${EXTRA_PATCHES_${OPSYS}_${OSREL:R}}
27
EXTRA_PATCHES_FreeBSD_9=	${FILESDIR}/extra-patch-src_client.c
27
28
28
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1001505
29
BROKEN=		This port requires ppoll(2) system call
30
.endif
31
32
post-patch:
29
post-patch:
33
	@${REINPLACE_CMD} -e 's|%%CC%%|${CC}|g' ${WRKSRC}/Make.defaults
30
	@${REINPLACE_CMD} -e 's|%%CC%%|${CC}|g' ${WRKSRC}/Make.defaults
34
31
Lines 43-46 do-install: Link Here
43
	${INSTALL_MAN} ${WRKSRC}/src/pesign-client.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
40
	${INSTALL_MAN} ${WRKSRC}/src/pesign-client.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
44
	${INSTALL_MAN} ${WRKSRC}/src/pesign.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
41
	${INSTALL_MAN} ${WRKSRC}/src/pesign.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
45
42
46
.include <bsd.port.post.mk>
43
.include <bsd.port.mk>
(-)sysutils/pesign/files/extra-patch-src_client.c (+52 lines)
Line 0 Link Here
1
--- src/client.c.orig	2014-10-24 19:51:06 UTC
2
+++ src/client.c
3
@@ -47,6 +47,49 @@ static struct {
4
 	{FLAG_LIST_END, NULL},
5
 };
6
 
7
+#if defined(__FreeBSD__) && __FreeBSD__ < 10
8
+/*-
9
+ * Copyright (c) 2013 Niclas Zeising
10
+ * All rights reserved.
11
+ *
12
+ * Redistribution and use in source and binary forms, with or without
13
+ * modification, are permitted provided that the following conditions
14
+ * are met:
15
+ * 1. Redistributions of source code must retain the above copyright
16
+ *    notice, this list of conditions and the following disclaimer.
17
+ * 2. Redistributions in binary form must reproduce the above copyright
18
+ *    notice, this list of conditions and the following disclaimer in the
19
+ *    documentation and/or other materials provided with the distribution.
20
+ *
21
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
22
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
25
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31
+ * SUCH DAMAGE.
32
+ *
33
+ * $FreeBSD: head/lib/libc/string/strchrnul.c 288004 2015-09-20 03:51:15Z rodrigc
34
+ */
35
+
36
+static char *
37
+strchrnul(const char *p, int ch)
38
+{
39
+	char c;
40
+
41
+	c = ch;
42
+	for (;; ++p) {
43
+		if (*p == c || *p == '\0')
44
+			return ((char *)p);
45
+	}
46
+	/* NOTREACHED */
47
+}
48
+#endif
49
+
50
 static void
51
 print_flag_name(FILE *f, int flag)
52
 {
(-)sysutils/pesign/files/patch-src-daemon.c (+9 lines)
Lines 8-13 Link Here
8
 #include <sys/types.h>
8
 #include <sys/types.h>
9
 #include <sys/socket.h>
9
 #include <sys/socket.h>
10
 #include <sys/stat.h>
10
 #include <sys/stat.h>
11
@@ -839,7 +838,7 @@ shutdown:
12
 			do_shutdown(ctx, nsockets, pollfds);
13
 			return 0;
14
 		}
15
-		rc = ppoll(pollfds, nsockets, NULL, NULL);
16
+		rc = poll(pollfds, nsockets, INFTIM);
17
 		if (should_exit != 0)
18
 			goto shutdown;
19
 		if (rc < 0) {
11
@@ -864,8 +863,8 @@ shutdown:
20
@@ -864,8 +863,8 @@ shutdown:
12
 
21
 
13
 			struct sockaddr_un remote;
22
 			struct sockaddr_un remote;

Return to bug 205039