pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/security/tcp_wrappers Teach security/tcp_wrappers to b...
details: https://anonhg.NetBSD.org/pkgsrc/rev/e37222812691
branches: trunk
changeset: 471324:e37222812691
user: jlam <jlam%pkgsrc.org@localhost>
date: Fri Mar 26 11:02:14 2004 +0000
description:
Teach security/tcp_wrappers to build on NetBSD systems. Remove the
ONLY_FOR_PLATFORMS setting and simply allow the build to fail on systems
on which it currently doesn't build. Replace the cascading if statement
that set the Makefile target with something more compact. Lastly, teach
tcp_wrappers to partially honor PKG_SYSCONFDIR -- it will default to the
historic locations /etc/host.{allow,deny} for the config files, but if
PKG_SYSCONFDIR.tcp_wrappers is set in /etc/mk.conf, then it will use that
instead.
diffstat:
security/tcp_wrappers/Makefile | 49 ++++++++++++++++++++++-----------
security/tcp_wrappers/distinfo | 4 +-
security/tcp_wrappers/patches/patch-aa | 27 ++++++++++++------
3 files changed, 53 insertions(+), 27 deletions(-)
diffs (156 lines):
diff -r f1cf13c2797d -r e37222812691 security/tcp_wrappers/Makefile
--- a/security/tcp_wrappers/Makefile Fri Mar 26 08:53:01 2004 +0000
+++ b/security/tcp_wrappers/Makefile Fri Mar 26 11:02:14 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.15 2004/02/10 09:06:55 grant Exp $
+# $NetBSD: Makefile,v 1.16 2004/03/26 11:02:14 jlam Exp $
DISTNAME= tcp_wrappers_7.6-ipv6.1
PKGNAME= tcp_wrappers-7.6.1
@@ -10,8 +10,6 @@
HOMEPAGE= ftp://ftp.porcupine.org/pub/security/index.html
COMMENT= Monitor and filter incoming requests for network services
-ONLY_FOR_PLATFORM= IRIX-*-* Darwin-*-* SunOS-*-* Linux-*-* # in NetBSD base system
-
PKG_INSTALLATION_TYPES= overwrite pkgviews
USE_BUILDLINK3= yes
@@ -19,21 +17,40 @@
.include "../../mk/bsd.prefs.mk"
-.if ${OPSYS} == "Darwin"
-ALL_TARGET= netbsd
-.elif ${OPSYS} == "SunOS"
-ALL_TARGET= sunos5
-.elif ${OPSYS} == "IRIX"
-ALL_TARGET= ${LOWER_OPSYS:C|\..*||}
-.elif ${OPSYS} == "Linux"
-ALL_TARGET= ${LOWER_OPSYS}
-.else
-ALL_TARGET= generic # good luck!
+ALL_TARGET.${OPSYS}?= generic # good luck!
+ALL_TARGET.Darwin= netbsd
+ALL_TARGET.Linux= ${LOWER_OPSYS}
+.if !empty(OPSYS:M*BSD)
+ALL_TARGET.${OPSYS}= netbsd
+.endif
+ALL_TARGET.SunOS= sunos5
+ALL_TARGET.IRIX= ${LOWER_OPSYS:C|\..*||}
+ALL_TARGET= ${ALL_TARGET.${OPSYS}}
+
+.if defined(USE_INET6) && !empty(USE_INET6:M[yY][eE][sS])
+. if !empty(OPSYS:M*BSD)
+MAKE_ENV+= IPV6="-DHAVE_IPV6 -DUSE_GETHOSTBYNAME2"
+MAKE_ENV+= UCHAR="-Duchar_t=\"unsigned char\""
+. elif ${OPSYS} != "Linux"
+MAKE_ENV+= IPV6=-DHAVE_IPV6
+. endif
.endif
-.if defined(USE_INET6) && ${USE_INET6} == "YES" && ${OPSYS} != "Linux"
-MAKE_ENV+= IPV6=-DHAVE_IPV6
-.endif
+# Default to /etc/hosts.{allow,deny} for the configuration files to match
+# the historic location of these files. This may be changed by setting
+# PKG_SYSCONFDIR.tcp_wrappers to a different value in /etc/mk.conf.
+#
+PKG_SYSCONFDIR.tcp_wrappers?= /etc
+MAKE_ENV+= PKGSYSCONFDIR=${PKG_SYSCONFDIR:Q}
+
+INSTALLATION_DIRS= bin include lib libexec man/man3 man/man5 man/man8
+
+post-build:
+ cd ${WRKSRC}; for file in *.[0-9]; do \
+ ${MV} -f $$file $$file.BAK; \
+ ${SED} -e "s|/etc/hosts\.|${PKG_SYSCONFDIR}/hosts.|g" \
+ $$file.BAK > $$file; \
+ done
do-install:
cd ${WRKSRC}; ${LIBTOOL} ${INSTALL_DATA} libwrap.la ${PREFIX}/lib
diff -r f1cf13c2797d -r e37222812691 security/tcp_wrappers/distinfo
--- a/security/tcp_wrappers/distinfo Fri Mar 26 08:53:01 2004 +0000
+++ b/security/tcp_wrappers/distinfo Fri Mar 26 11:02:14 2004 +0000
@@ -1,8 +1,8 @@
-$NetBSD: distinfo,v 1.6 2004/03/21 19:49:05 bouyer Exp $
+$NetBSD: distinfo,v 1.7 2004/03/26 11:02:14 jlam Exp $
SHA1 (tcp_wrappers_7.6-ipv6.1.tar.gz) = d0b70d4f0c0ac0375d8283a18ec2b6d602f82fde
Size (tcp_wrappers_7.6-ipv6.1.tar.gz) = 144708 bytes
-SHA1 (patch-aa) = 4158e67803e39d9cf0469bc1961ea2a1e6d672e2
+SHA1 (patch-aa) = feed6e504bb69c210ede443289de3a3b19bc0332
SHA1 (patch-ab) = 51b094f55afcea6ef1063af1b27be0b22b07eaa6
SHA1 (patch-ac) = a9cd493a470782e8f6bdd38fde6c746fb1e371c0
SHA1 (patch-ad) = 2f2fa789599e2fca652e240f05bec8460287e79e
diff -r f1cf13c2797d -r e37222812691 security/tcp_wrappers/patches/patch-aa
--- a/security/tcp_wrappers/patches/patch-aa Fri Mar 26 08:53:01 2004 +0000
+++ b/security/tcp_wrappers/patches/patch-aa Fri Mar 26 11:02:14 2004 +0000
@@ -1,8 +1,8 @@
-$NetBSD: patch-aa,v 1.5 2003/06/10 17:58:34 jschauma Exp $
+$NetBSD: patch-aa,v 1.6 2004/03/26 11:02:14 jlam Exp $
---- Makefile.orig Mon Aug 21 10:59:52 2000
-+++ Makefile Tue Jun 10 10:29:53 2003
-@@ -44,7 +44,7 @@
+--- Makefile.orig Mon Aug 21 13:59:52 2000
++++ Makefile
+@@ -44,7 +44,7 @@ what:
#REAL_DAEMON_DIR=/usr/etc
#
# SysV.4 Solaris 2.x OSF AIX
@@ -11,7 +11,7 @@
#
# BSD 4.4
#REAL_DAEMON_DIR=/usr/libexec
-@@ -144,7 +144,7 @@
+@@ -144,7 +144,7 @@ freebsd:
linux:
@make REAL_DAEMON_DIR=$(REAL_DAEMON_DIR) STYLE=$(STYLE) \
LIBS= RANLIB=ranlib ARFLAGS=rv AUX_OBJ=setenv.o \
@@ -20,7 +20,7 @@
# This is good for many SYSV+BSD hybrids with NIS, probably also for HP-UX 7.x.
hpux hpux8 hpux9 hpux10:
-@@ -185,6 +185,7 @@
+@@ -185,6 +185,7 @@ irix5:
# IRIX 6.2 (tucker%math.unc.edu@localhost). Must find a better value than 200000.
irix6:
@@ -28,7 +28,16 @@
@make REAL_DAEMON_DIR=$(REAL_DAEMON_DIR) STYLE=$(STYLE) \
LIBS= RANLIB=echo ARFLAGS=rv VSYSLOG= \
NETGROUP=-DNETGROUP EXTRA_CFLAGS="-DBSD=200000" TLI= all
-@@ -669,7 +670,7 @@
+@@ -602,7 +603,7 @@ ACCESS = -DHOSTS_ACCESS
+ # look for access control information. Watch out for the quotes and
+ # backslashes when you make changes.
+
+-TABLES = -DHOSTS_DENY=\"/etc/hosts.deny\" -DHOSTS_ALLOW=\"/etc/hosts.allow\"
++TABLES = -DHOSTS_DENY=\"${PKG_SYSCONFDIR}/hosts.deny\" -DHOSTS_ALLOW=\"${PKG_SYSCONFDIR}/hosts.allow\"
+
+ ####################################################
+ # Optional: dealing with host name/address conflicts
+@@ -669,7 +670,7 @@ HOSTNAME= -DALWAYS_HOSTNAME
# Protection against weird shells or weird make programs.
SHELL = /bin/sh
@@ -37,7 +46,7 @@
CFLAGS = -O -DFACILITY=$(FACILITY) $(ACCESS) $(PARANOID) $(NETGROUP) \
$(BUGS) $(SYSTYPE) $(AUTH) $(UMASK) \
-@@ -696,7 +697,7 @@
+@@ -696,7 +697,7 @@ KIT = README miscd.c tcpd.c fromhost.c h
refuse.c tcpdchk.8 setenv.c inetcf.c inetcf.h scaffold.c \
scaffold.h tcpdmatch.8 README.NIS
@@ -46,7 +55,7 @@
all other: config-check tcpd tcpdmatch try-from safe_finger tcpdchk
-@@ -713,31 +714,29 @@
+@@ -713,31 +714,29 @@ config-check:
cflags: config-check
$(LIB): $(LIB_OBJ)
Home |
Main Index |
Thread Index |
Old Index