- The current fwtk port will not build on FreeBSD => 5.x, this is

because of the S/Key library requirements.  Moved the S/Key support
  behind the WITH_SKEY knob and added a WITH_SNK knob as well.  Now
  the system will build on FreeBSD 6.1 systems if WITH_SKEY is NOT
  set.
- Change varargs.h to stdarg.h, to build with the newer version of gcc.
- Pass the maintainership to submitter.
- Bump PORTREVISION

PR:		ports/97633
Submitted by:	pirzyk
This commit is contained in:
Renato Botelho 2006-06-01 15:33:32 +00:00
parent 9e4ac3c605
commit 4f96abae66
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=164155
7 changed files with 130 additions and 53 deletions

View file

@ -1,4 +1,3 @@
# ex:ts=8
# Ports collection makefile for: fwtk
# Date created: 15th June 1996
# Whom: gpalmer
@ -8,22 +7,22 @@
PORTNAME= fwtk
PORTVERSION= 2.1
PORTREVISION= 1
CATEGORIES= security
DISTNAME= ${PORTNAME}${PORTVERSION}
EXTRACT_SUFX= .tar.Z
DISTFILES= fwtk2.1${EXTRACT_SUFX} fwtk-doc-only${EXTRACT_SUFX}
DIST_SUBDIR= fwtk
.if defined(WITH_JUMBO_PATCH)
PATCHFILES= trg-jumbo-20001114.diff
PATCH_SITES= http://www.fwtk.org/fwtk/patches/
PATCH_DIST_STRIP= -p1
.endif
MAINTAINER= ports@FreeBSD.org
MAINTAINER= pirzyk@FreeBSD.org
COMMENT= A toolkit used for building firewalls based on proxy services
RESTRICTED= "No form of redistribution is allowed"
RESTRICTED= No form of redistribution is allowed
OPTIONS= X11 "Build X11 programs" On \
JUMBO_PATCH "Build with the \"Jumbo\" patch kit" Off \
SKEY "Build this package with S/Key support" Off \
SNK "Buil this package with DigiPath SNK support" Off
WRKSRC= ${WRKDIR}/fwtk
HAS_CONFIGURE= YES
@ -32,22 +31,31 @@ CONFIGURE_SCRIPT= fixmake
MAN3= auth.3
MAN5= netperm-table.5
MAN8= authmgr.8 authsrv.8 ftp-gw.8 http-gw.8 login-sh.8 netacl.8 \
plug-gw.8 rlogin-gw.8 smap.8 smapd.8 tn-gw.8
plug-gw.8 rlogin-gw.8 smap.8 smapd.8 tn-gw.8 x-gw.8
DOCS= sample-report.txt manpages.ps admin_guide.ps user_guide.ps \
overview.ps presentation.ps
SBIN_BINS= authdump authload authmgr
LIBEXEC_BINS= authsrv ftp-gw http-gw netacl plug-gw rlogin-gw smap smapd \
tn-gw
.if !defined(WITHOUT_X11)
LIBEXEC_BINS+= x-gw
MAN8+= x-gw.8
.endif
tn-gw x-gw
.include <bsd.port.pre.mk>
.if ${OSVERSION} >= 500000
IGNORE= does not build on 5.x and above, requires S/Key libraries and headers
.if defined(WITH_SKEY)
IGNORE= does not build on 5.x and above with WITH_SKEY set because it requires S/Key libraries and headers
.endif
.endif
.if !defined(WITHOUT_X11)
MAN8+= x-gw.8
LIBEXEC_BINS+= x-gw
USE_XLIB= yes
.endif
.if defined(WITH_JUMBO_PATCH)
PATCHFILES= trg-jumbo-20001114.diff
PATCH_SITES= http://www.fwtk.org/fwtk/patches/
PATCH_DIST_STRIP= -p1
.endif
.if !exists(${DISTDIR}/${DIST_SUBDIR}/fwtk2.1${EXTRACT_SUFX}) \
@ -55,12 +63,18 @@ IGNORE= does not build on 5.x and above, requires S/Key libraries and headers
IGNORE='Please read ftp://ftp.tislabs.com/pub/firewalls/toolkit/dist/README for details of how to obtain the FTWK source. Put the files fwtk2.1${EXTRACT_SUFX} and fwtk-doc-only${EXTRACT_SUFX} into the directory ${DISTDIR}/${DIST_SUBDIR} and run make again'
.endif
pre-patch:
.if !defined(WITH_JUMBO_PATCH)
@${ECHO} "*****************************************************************************"
@${ECHO} "**** To enable the \"Jumbo\" patch kit, run 'make -DWITH_JUMBO_PATCH'"
@${ECHO} "**** For information about patches, read http://www.fwtk.org/fwtk/patches/"
@${ECHO} "*****************************************************************************"
post-patch:
@${REINPLACE_CMD} -e 's|<varargs.h>|<stdarg.h>|' \
${WRKSRC}/http-gw/http-gw.h
@${REINPLACE_CMD} -E 's|(defined\(AIX\))|\1 \&\& !defined(__FreeBSD__)|' \
${WRKSRC}/x-gw/sig.c
.if defined(WITH_SKEY)
@${REINPLACE_CMD} -E 's|^/\* (#define AUTHPROTO_SKEY) \*/|\1|' \
${WRKSRC}/auth.h
.endif
.if defined(WITH_SNK)
@${REINPLACE_CMD} -E 's|^/\* (#define AUTHPROTO_SNK) \*/|\1|' \
${WRKSRC}/auth.h
.endif
pre-configure:
@ -74,7 +88,7 @@ pre-configure:
${WRKSRC}/firewall.h.in > ${WRKSRC}/firewall.h
post-install:
cd ${PREFIX}/libexec ; strip ${SBIN_BINS} ${LIBEXEC_BINS}
cd ${PREFIX}/libexec ; ${STRIP_CMD} ${SBIN_BINS} ${LIBEXEC_BINS}
cd ${PREFIX}/libexec ; ${MV} ${SBIN_BINS} mqueue ../sbin
${INSTALL_DATA} ${WRKSRC}/config/netperm-table \
${PREFIX}/etc/netperm-table.sample

View file

@ -1,5 +1,9 @@
MD5 (fwtk/fwtk2.1.tar.Z) = 936bf217fc271c54ef4b5ffca1e642db
SHA256 (fwtk/fwtk2.1.tar.Z) = 776fe265b89cb0df2f39c0edb93b1b84dc5af8300d599150dbf517f5f8f224be
SIZE (fwtk/fwtk2.1.tar.Z) = 481055
MD5 (fwtk/fwtk-doc-only.tar.Z) = 74ab67a3d224ba7ce0cfc2a39cb038cf
SHA256 (fwtk/fwtk-doc-only.tar.Z) = cf95d9f650bc6b88d5cac9bd38a809d1e30faa372d0585b3a63773cfe7f2066a
SIZE (fwtk/fwtk-doc-only.tar.Z) = 423991
MD5 (trg-jumbo-20001114.diff) = 32d8139ffc8826f451c4df80c5640d5a
MD5 (fwtk/trg-jumbo-20001114.diff) = 32d8139ffc8826f451c4df80c5640d5a
SHA256 (fwtk/trg-jumbo-20001114.diff) = 8270366706260bf9bbb0f679746dd5fc804a23cdb9929615be0f4cd3863c8e9d
SIZE (fwtk/trg-jumbo-20001114.diff) = 5678

View file

@ -1,11 +1,13 @@
--- Makefile.config.orig Tue Mar 4 20:17:46 1997
+++ Makefile.config Sat Apr 18 00:51:14 1998
@@ -24,13 +24,13 @@
--- Makefile.config.orig Tue Mar 4 22:17:46 1997
+++ Makefile.config Sun May 21 18:01:05 2006
@@ -24,13 +24,15 @@
# Defines for your operating system
#
-DEFINES=
+.if defined(WITH_SKEY)
+DEFINES= -D_SKEY_INTERNAL
+.endif
#DEFINES=-DSYSV -DSOLARIS
# Options for your compiler (eg, "-g" for debugging, "-O" for
@ -16,7 +18,7 @@
#COPT= -O $(DEFINES)
# Version of "make" you want to use
@@ -44,16 +44,16 @@
@@ -44,16 +46,20 @@
# Destination directory for installation of binaries
@ -32,11 +34,15 @@
# Names of any auxiliary libraries your system may require (e.g., -lsocket)
# If you want to link against a resolver library, specify it here.
-AUXLIB=
+.if defined(WITH_SKEY)
+AUXLIB= -lcrypt -lskey -lmd
+.else
+AUXLIB= -lcrypt -lmd
+.endif
#AUXLIB= -lsocket
#AUXLIB= -lresolv
# For Solaris:
@@ -72,23 +72,23 @@
@@ -72,23 +78,23 @@
# or -Bstatic for static binaries under SunOS 4.1.x)
#LDFL= -Bstatic
#LDFL=
@ -64,7 +70,7 @@
#XLIBS = -L$(XLIBDIR) -lXaw -lXmu -lXt -lXext -lX11
# for Linux:
#XLIBS = -L$(XLIBDIR) -lXaw -lXmu -lXt -lXext -lX11 -lc
@@ -98,8 +98,8 @@
@@ -98,8 +104,8 @@
#XLIBS = -L$(XLIBDIR) -lXaw -lXmu -lXt -lXext -lX11
# Location of X include files

View file

@ -1,11 +0,0 @@
--- auth.h.orig Fri Nov 4 15:31:26 1994
+++ auth.h Sat Apr 18 00:37:48 1998
@@ -69,7 +69,7 @@
#define AUTHPROTO_PASSWORD
/* define this if you want to use bellcore's S/Key */
-/* #define AUTHPROTO_SKEY */
+#define AUTHPROTO_SKEY
/* define this if you want to use Security Dynamics' SecurID */
/* #define AUTHPROTO_SECURID */

View file

@ -1,11 +1,51 @@
--- auth/Makefile.orig Fri Apr 5 09:49:21 1996
+++ auth/Makefile Sat Apr 18 00:38:57 1998
@@ -20,7 +20,7 @@
--- auth/Makefile.orig Fri Apr 5 11:49:21 1996
+++ auth/Makefile Sun May 21 22:42:13 2006
@@ -12,7 +12,7 @@
# RcsId: "$Header: /usr/home/rick/fwtk2.0/fwtk/auth/RCS/Makefile,v 1.1 1996/03/27 03:29:55 rick Exp rick $"
-include ../Makefile.config
+.include "../Makefile.config"
#if you are using the SKEY modules, define SKEYDIR to be the source
@@ -20,7 +20,9 @@
#SKEYDIR=../../skey
#SKEYINC= -I$(SKEYDIR)
#SKEYLIB= $(SKEYDIR)/libskey.a
-#SKEYOBJ= skey.o
+.if defined(WITH_SKEY)
+SKEYOBJ= skey.o
+.endif
#if you are using the SecurID module, define SECURDIR to be the source
@@ -41,20 +43,24 @@
#if you are using the Digital Pathways SNK module, include this:
#this also requires DES routines below
-#SNKOBJ= snk.o
+.if defined(WITH_SNK)
+SNKOBJ= snk.o
+.endif
#if you are using link-level encryption code, this should be the path
#to a library that contains DES routines (NOT SUPPLIED!)
#you will need to replace srvio.c and cliio.c
-#DESLIB= ../../libdes/libdes.a
-#DESINC= -I../../libdes
+.if defined(WITH_SNK)
+DESLIB= -lcrypto
+DESINC= -I/usr/include/openssl
+.endif
#security protocol modules
MODULES= $(SKEYLIB) $(SECURLIB) $(DESLIB)
-CFLAGS= -I.. $(COPT)
+CFLAGS+= -I.. $(COPT)
LIB= ../libauth.a
FWLIB= ../libfwall.a

View file

@ -0,0 +1,24 @@
--- http-gw/error.c.orig Tue Jan 13 20:21:28 1998
+++ http-gw/error.c Sun May 21 22:09:19 2006
@@ -174,11 +174,7 @@
return 0;
}
-int go_error(sockfd, errorno, msg, va_alist)
-int sockfd;
-int errorno;
-char *msg;
-va_dcl
+int go_error(int sockfd, int errorno, char *msg, ...)
{ static int last_errno = 0;
va_list marker;
@@ -192,7 +188,7 @@
}
}
if( msg != NULL){
- va_start(marker);
+ va_start(marker, msg);
vsprintf(errbuf, msg, marker);
va_end(marker);
if( (rem_type & (TYPE_HTTP|TYPE_DIR)) == (TYPE_DIR)){

View file

@ -14,11 +14,11 @@ sbin/authdump
sbin/authload
sbin/authmgr
sbin/mqueue
%%PORTDOCS%%share/doc/fwtk/LICENSE
%%PORTDOCS%%share/doc/fwtk/admin_guide.ps
%%PORTDOCS%%share/doc/fwtk/manpages.ps
%%PORTDOCS%%share/doc/fwtk/overview.ps
%%PORTDOCS%%share/doc/fwtk/presentation.ps
%%PORTDOCS%%share/doc/fwtk/sample-report.txt
%%PORTDOCS%%share/doc/fwtk/user_guide.ps
%%PORTDOCS%%@dirrm share/doc/fwtk
%%PORTDOCS%%%%DOCSDIR%%/LICENSE
%%PORTDOCS%%%%DOCSDIR%%/admin_guide.ps
%%PORTDOCS%%%%DOCSDIR%%/manpages.ps
%%PORTDOCS%%%%DOCSDIR%%/overview.ps
%%PORTDOCS%%%%DOCSDIR%%/presentation.ps
%%PORTDOCS%%%%DOCSDIR%%/sample-report.txt
%%PORTDOCS%%%%DOCSDIR%%/user_guide.ps
%%PORTDOCS%%@dirrm %%DOCSDIR%%