pkgsrc-WIP-changes archive

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

libreswan: fix some issues



Module Name:	pkgsrc-wip
Committed By:	Thomas Klausner <wiz%gatalith.at@localhost>
Pushed By:	wiz
Date:		Fri Jun 17 00:55:31 2022 +0200
Changeset:	f3d1192dc45ce3dccf87493fb69a223212b10fcd

Modified Files:
	libreswan/Makefile
	libreswan/PLIST
	libreswan/TODO
	libreswan/distinfo
Added Files:
	libreswan/patches/patch-kvm
	libreswan/patches/patch-mk_defaults_netbsd.mk
Removed Files:
	libreswan/patches/patch-b_mk_defaults_netbsd.mk

Log Message:
libreswan: fix some issues

Add TODO item: etc/ files need to be handled

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=f3d1192dc45ce3dccf87493fb69a223212b10fcd

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 libreswan/Makefile                              | 11 ++++++++---
 libreswan/PLIST                                 | 10 ++++++++++
 libreswan/TODO                                  |  3 +++
 libreswan/distinfo                              |  3 ++-
 libreswan/patches/patch-b_mk_defaults_netbsd.mk | 21 ---------------------
 libreswan/patches/patch-kvm                     | 25 +++++++++++++++++++++++++
 libreswan/patches/patch-mk_defaults_netbsd.mk   | 19 +++++++++++++++++++
 7 files changed, 67 insertions(+), 25 deletions(-)

diffs:
diff --git a/libreswan/Makefile b/libreswan/Makefile
index c12828d3b7..c8a4b79841 100644
--- a/libreswan/Makefile
+++ b/libreswan/Makefile
@@ -24,14 +24,19 @@ USE_TOOLS+=	bison
 
 DEPENDS+=	xmlto-[0-9]*:../../textproc/xmlto
 # weak dependency
-#DEPENDS+=	logrotate:../../sysutils/logrotate
+#DEPENDS+=	logrotate-[0-9]*:../../sysutils/logrotate
 
-# libreswan has GIT style patches
-PATCH_STRIP= -p1
+CHECK_PORTABILITY_SKIP=	mk/docker-targets.mk
+
+# code not clean enough
+BUILDLINK_TRANSFORM+=	rm:-Werror
+
+MAKE_FLAGS+=	PYTHON_BINARY=${PYTHONBIN}
 
 # libevent?
 .include "../../net/unbound/buildlink3.mk"
 .include "../../www/curl/buildlink3.mk"
 .include "../../devel/nss/buildlink3.mk"
 .include "../../net/ldns/buildlink3.mk"
+.include "../../lang/python/application.mk"
 .include "../../mk/bsd.pkg.mk"
diff --git a/libreswan/PLIST b/libreswan/PLIST
index 062afa016b..b41a082681 100644
--- a/libreswan/PLIST
+++ b/libreswan/PLIST
@@ -1,4 +1,14 @@
 @comment $NetBSD$
+etc/ipsec.conf
+etc/ipsec.d/policies/block
+etc/ipsec.d/policies/clear
+etc/ipsec.d/policies/clear-or-private
+etc/ipsec.d/policies/portexcludes.conf
+etc/ipsec.d/policies/private
+etc/ipsec.d/policies/private-or-clear
+etc/ipsec.secrets
+etc/logrotate.d/libreswan
+etc/rc.d/pluto
 libexec/ipsec/_import_crl
 libexec/ipsec/_plutorun
 libexec/ipsec/_realsetup
diff --git a/libreswan/TODO b/libreswan/TODO
index 4a77021535..119ea5fdfd 100644
--- a/libreswan/TODO
+++ b/libreswan/TODO
@@ -14,3 +14,6 @@
   During install, libreswan creates logrotate.d and then installs
   a logrotate file.  It doesn't install the file in examples
   (which begs the question where).
+
+- fix handling of config files - install into share/examples/libreswan
+  and use CONF_FILES
diff --git a/libreswan/distinfo b/libreswan/distinfo
index 4da50c8808..fe7446fde3 100644
--- a/libreswan/distinfo
+++ b/libreswan/distinfo
@@ -3,4 +3,5 @@ $NetBSD$
 BLAKE2s (libreswan-4.7.tar.gz) = 952887f1381b00a672e05e9baa4d4bb899cd07c4809dc8f365fc06e9791cbd6d
 SHA512 (libreswan-4.7.tar.gz) = aea958be5512e08ea809145021695edd4e7df4487a0f3ba94c4d0165113647195c1c1599cd5fbbbfae8f6a2bebf39d7514a694f86297c29c543b1a63646ca44e
 Size (libreswan-4.7.tar.gz) = 3684167 bytes
-SHA1 (patch-b_mk_defaults_netbsd.mk) = 90e58c1bb06dd3f67006c5cffb3b0b02a5ec2b1e
+SHA1 (patch-kvm) = 7864fd394df006829ab758d579d248d3cc0defb8
+SHA1 (patch-mk_defaults_netbsd.mk) = 36e3b00088466d0c8ea7ed85e5581d42a374e419
diff --git a/libreswan/patches/patch-b_mk_defaults_netbsd.mk b/libreswan/patches/patch-b_mk_defaults_netbsd.mk
deleted file mode 100644
index 27ca0391f2..0000000000
--- a/libreswan/patches/patch-b_mk_defaults_netbsd.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-$NetBSD$
-
-Backport patch from upstream.
-
-commit 8861abd461ad049f915fb4aad8ac123188f407a7
-Author: Andrew Cagney <cagney%gnu.org@localhost>
-Date:   Tue Jun 14 20:54:55 2022 -0400
-
-    NetBSD: install manual pages in $(PREFIX)/man
-    
-    not share/man
-
-diff --git a/mk/defaults/netbsd.mk b/mk/defaults/netbsd.mk
-index 4c623089f5..d9e3d262f8 100644
---- a/mk/defaults/netbsd.mk
-+++ b/mk/defaults/netbsd.mk
-@@ -33,3 +33,4 @@ FINALRUNDIR=/var/run/pluto
- FINALSYSCONFDIR=$(PREFIX)/etc
- FINALNSSDIR=$(PREFIX)/etc/ipsec.d
- FINALEXAMPECONFDIR=$(PREFIX)/share/examples/libreswan
-+FINALMANDIR=$(PREFIX)/man
diff --git a/libreswan/patches/patch-kvm b/libreswan/patches/patch-kvm
new file mode 100644
index 0000000000..c5c1f25e56
--- /dev/null
+++ b/libreswan/patches/patch-kvm
@@ -0,0 +1,25 @@
+$NetBSD$
+
+Fix unportable test(1) operator.
+
+--- kvm.orig	2022-05-24 17:23:22.000000000 +0000
++++ kvm
+@@ -164,15 +164,15 @@ BEGIN {
+ #
+ # ${pass1}, ${pass2} and ${hosts} contain completion values.
+ 
+-if test "$1" == $0 -a $# -eq 3 ; then
++if test "$1" = $0 -a $# -eq 3 ; then
+     command=$1
+     word=$2
+     previous=$3
+     # hack to detect first vs later argument
+-    if test "${previous}" == "${command}" ; then
++    if test "${previous}" = "${command}" ; then
+ 	# first command
+ 	compgen -W "${pass1} ${pass2}" "${word}" | sort
+-    elif test "${previous}" == sh ; then
++    elif test "${previous}" = sh ; then
+ 	# pass 1 command
+ 	compgen -W "${hosts}" "${word}"
+     else
diff --git a/libreswan/patches/patch-mk_defaults_netbsd.mk b/libreswan/patches/patch-mk_defaults_netbsd.mk
new file mode 100644
index 0000000000..2c315ab04c
--- /dev/null
+++ b/libreswan/patches/patch-mk_defaults_netbsd.mk
@@ -0,0 +1,19 @@
+$NetBSD$
+
+Backport patch from upstream.
+
+commit 8861abd461ad049f915fb4aad8ac123188f407a7
+Author: Andrew Cagney <cagney%gnu.org@localhost>
+Date:   Tue Jun 14 20:54:55 2022 -0400
+
+    NetBSD: install manual pages in $(PREFIX)/man
+
+    not share/man
+
+--- mk/defaults/netbsd.mk.orig	2022-05-24 17:23:22.000000000 +0000
++++ mk/defaults/netbsd.mk
+@@ -30,3 +30,4 @@ FINALRUNDIR=/var/run/pluto
+ FINALSYSCONFDIR=$(PREFIX)/etc
+ FINALNSSDIR=$(PREFIX)/etc/ipsec.d
+ FINALEXAMPECONFDIR=$(PREFIX)/share/examples/libreswan
++FINALMANDIR=$(PREFIX)/man


Home | Main Index | Thread Index | Old Index