1999-11-23 22:23:05 -05:00
|
|
|
# $OpenBSD: Makefile,v 1.11 1999/11/24 03:23:05 brad Exp $
|
1999-06-02 12:27:26 -04:00
|
|
|
|
1998-03-19 23:05:10 -05:00
|
|
|
DISTNAME= pgp263is
|
|
|
|
PKGNAME= pgp-2.6.3
|
|
|
|
CATEGORIES= security
|
1999-11-23 22:23:05 -05:00
|
|
|
MASTER_SITES= http://the.wiretapped.net/security/cryptography/pgp/2.x/src/ \
|
|
|
|
ftp://ftp.ifi.uio.no/pub/pgp/2.x/src/ \
|
1998-03-19 23:05:10 -05:00
|
|
|
ftp://ftp.dk.pgpi.com/mirrors/ftp.ifi.uio.no/pub/pgp/2.x/src/
|
1999-11-23 22:23:05 -05:00
|
|
|
MASTER_SITES0= http://the.wiretapped.net/security/cryptography/libs/rsa/ \
|
|
|
|
ftp://idea.dsi.unimi.it/pub/security/crypt/math/ \
|
|
|
|
ftp://ftp.it.net.au/mirrors/crypto/misc
|
1998-03-19 23:05:10 -05:00
|
|
|
|
1999-11-23 22:23:05 -05:00
|
|
|
NEED_VERSION= 1.121
|
1999-06-02 12:27:26 -04:00
|
|
|
|
1998-03-19 23:05:10 -05:00
|
|
|
MAINTAINER= ports@openbsd.org
|
|
|
|
|
1999-06-02 12:27:26 -04:00
|
|
|
NO_CDROM= "CRYPTO: Third party crypto not allowed."
|
1998-03-19 23:05:10 -05:00
|
|
|
RESTRICTED= "Crypto; export-controlled"
|
1999-11-23 22:23:05 -05:00
|
|
|
|
1999-06-02 12:27:26 -04:00
|
|
|
IS_INTERACTIVE= yes
|
1999-11-23 22:23:05 -05:00
|
|
|
WRKSRC= ${WRKDIR}/src
|
|
|
|
|
|
|
|
.if defined(NO_WARNINGS) || (defined(USA_RESIDENT) && ${USA_RESIDENT:U} == YES)
|
|
|
|
DISTFILES= ${DISTNAME}.tar.gz rsaref2.tar.gz:0
|
|
|
|
.endif
|
|
|
|
|
|
|
|
# common C flags
|
|
|
|
CFLAGS+=-DUNIX -DPORTABLE -DMERIT -DIDEA32 -DMAX_NAMELEN=255 \
|
|
|
|
-DPGP_DOC_DIR=\\\"${PGP_DOC_DIR}\\\"
|
|
|
|
|
|
|
|
.if defined(USA_RESIDENT) && ${USA_RESIDENT:U} == YES
|
|
|
|
RSAOBJS= rsaglue2.o
|
|
|
|
RSADIR= ../rsaref2
|
|
|
|
RSAINCDIR= -I$(RSADIR)/source -I$(RSADIR)/test
|
|
|
|
RSALIBDIR= $(RSADIR)/install/unix
|
|
|
|
RSALIBS= $(RSALIBDIR)/rsaref.a
|
|
|
|
CFLAGS+= -DUSA ${RSAINCDIR}
|
|
|
|
.else
|
|
|
|
RSAOBJS= rsaglue1.o
|
|
|
|
.endif
|
|
|
|
|
|
|
|
PATCH_LIST= patch-doc
|
|
|
|
.if defined(USA_RESIDENT) && ${USA_RESIDENT:U} == YES
|
|
|
|
PATCH_LIST+= patch-rsaref2
|
|
|
|
.else
|
1998-03-19 23:05:10 -05:00
|
|
|
.endif
|
|
|
|
|
1999-11-23 22:23:05 -05:00
|
|
|
PGP_DOC_DIR=${PREFIX}/share/doc/pgp
|
|
|
|
|
|
|
|
# library and doc files to install
|
|
|
|
LIBFILES= config.txt de.hlp en.hlp es.hlp fr.hlp keys.asc \
|
|
|
|
language.txt pgp.hlp
|
|
|
|
|
|
|
|
DOCFILES= appnote.doc blurb.txt changes.doc faq.txt keyserv.doc \
|
|
|
|
mitlicen.txt pgformat.doc pgp262i.dif pgp263i.dif \
|
|
|
|
pgp_vms.hlp pgpdoc1.txt pgpdoc2.txt politic.doc przon26i.asc
|
|
|
|
|
1998-03-19 23:05:10 -05:00
|
|
|
fetch-depends:
|
1999-06-02 12:27:26 -04:00
|
|
|
.if !defined(NO_WARNINGS)
|
1999-11-23 22:23:05 -05:00
|
|
|
.if !defined(USA_RESIDENT) || ${USA_RESIDENT:U} != YES && ${USA_RESIDENT:U} != NO
|
1998-03-19 23:05:10 -05:00
|
|
|
@${ECHO}
|
|
|
|
@${ECHO} You must set variable USA_RESIDENT to YES if you are a USA
|
|
|
|
@${ECHO} resident or NO otherwise. USA residents must obtain the
|
|
|
|
@${ECHO} RSAREF2 library to generate this program. \(RSA Inc. holds
|
1998-08-28 19:00:43 -04:00
|
|
|
@${ECHO} a patent on RSA in the USA - using RSA implementations
|
|
|
|
@${ECHO} other than RSAREF in the USA will violate the US patent\).
|
1998-03-19 23:05:10 -05:00
|
|
|
@${ECHO} ""
|
|
|
|
@${ECHO} RSAREF2 will be automatically obtained and used to generate
|
|
|
|
@${ECHO} this program when given the command \"make USA_RESIDENT=YES\"
|
|
|
|
@${ECHO} ""
|
|
|
|
@${FALSE}
|
|
|
|
.endif
|
1998-12-16 15:24:50 -05:00
|
|
|
.endif
|
1998-03-19 23:05:10 -05:00
|
|
|
|
|
|
|
# 2nd level extract required
|
|
|
|
post-extract:
|
1999-06-02 12:27:26 -04:00
|
|
|
@if ! (cd ${WRKDIR} && ${TAR} -xf pgp263ii.tar); then \
|
1998-03-19 23:05:10 -05:00
|
|
|
exit 1; \
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Before the build figure out if we are on a big endian machine or not
|
|
|
|
pre-build:
|
1999-06-02 12:27:26 -04:00
|
|
|
@${ECHO} "#include <machine/endian.h>" > ${WRKDIR}/.endian.c
|
|
|
|
@${ECHO} "BYTE_ORDER" >> ${WRKDIR}/.endian.c
|
1998-03-22 20:40:06 -05:00
|
|
|
@${CC} -E ${WRKDIR}/.endian.c > ${WRKDIR}/.endian.out
|
1999-06-02 12:27:26 -04:00
|
|
|
@if { ${GREP} -q 4321 ${WRKDIR}/.endian.out; } then \
|
|
|
|
${ECHO} -DHIGHFIRST > ${WRKDIR}/.endian; \
|
1998-03-19 23:05:10 -05:00
|
|
|
else \
|
|
|
|
${CP} /dev/null ${WRKDIR}/.endian; \
|
|
|
|
fi
|
|
|
|
|
|
|
|
do-build:
|
1999-11-23 22:23:05 -05:00
|
|
|
.if defined(USA_RESIDENT) && ${USA_RESIDENT:U} == YES
|
1998-03-19 23:05:10 -05:00
|
|
|
@(cd ${WRKDIR}/rsaref2/install/unix && \
|
|
|
|
${SETENV} ${MAKE_ENV} ${MAKE} -f makefile rsaref.a)
|
|
|
|
.endif
|
|
|
|
@(cd ${WRKSRC} && \
|
|
|
|
${SETENV} ${MAKE_ENV} ${MAKE} -f makefile all \
|
|
|
|
RSAOBJS="${RSAOBJS}" RSADIR="${RSADIR}" RSAINCDIR="${RSAINCDIR}" \
|
|
|
|
RSALIBDIR="${RSALIBDIR}" RSALIBS="${RSALIBS}" \
|
1999-06-02 12:27:26 -04:00
|
|
|
CFLAGS="${CFLAGS} `${CAT} ${WRKDIR}/.endian`" )
|
1998-03-19 23:05:10 -05:00
|
|
|
|
|
|
|
do-install:
|
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/pgp ${PREFIX}/bin
|
|
|
|
@${INSTALL_MAN} ${WRKDIR}/doc/pgp.1 ${PREFIX}/man/man1
|
1999-11-23 22:23:05 -05:00
|
|
|
@${MKDIR} ${PREFIX}/lib/pgp
|
1998-03-19 23:05:10 -05:00
|
|
|
.for libfile in ${LIBFILES}
|
|
|
|
@${INSTALL_DATA} ${WRKDIR}/${libfile} ${PREFIX}/lib/pgp
|
|
|
|
.endfor
|
1999-11-23 22:23:05 -05:00
|
|
|
@${MKDIR} ${PGP_DOC_DIR}
|
1999-04-02 08:31:03 -05:00
|
|
|
@${INSTALL_DATA} ${WRKDIR}/setup.doc ${PGP_DOC_DIR}
|
1998-03-19 23:05:10 -05:00
|
|
|
.for docfile in ${DOCFILES}
|
1999-04-02 08:31:03 -05:00
|
|
|
@${INSTALL_DATA} ${WRKDIR}/doc/${docfile} ${PGP_DOC_DIR}
|
1998-03-19 23:05:10 -05:00
|
|
|
.endfor
|
|
|
|
|
|
|
|
.include <bsd.port.mk>
|