[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / security / openssl

File: [cvs.NetBSD.org] / pkgsrc / security / openssl / Makefile (download)

Revision 1.111, Sat Dec 17 05:20:23 2005 UTC (17 years, 1 month ago) by jlam
Branch: MAIN
CVS Tags: pkgsrc-2005Q4-base, pkgsrc-2005Q4
Changes since 1.110: +2 -2 lines

Change my MAINTAINER email address to the one I've been using for
pkgsrc work.

# $NetBSD: Makefile,v 1.111 2005/12/17 05:20:23 jlam Exp $

OPENSSL_SNAPSHOT?=	# empty
OPENSSL_STABLE?=	# empty
OPENSSL_VERS?=		0.9.7i

.if empty(OPENSSL_SNAPSHOT)
DISTNAME=	openssl-${OPENSSL_VERS}
MASTER_SITES=	http://mirrors.isc.org/pub/openssl/source/ \
		http://www.mirrors.wiretapped.net/security/cryptography/libraries/tls/openssl/ \
		http://sunsite.rediris.es/pub/mirror/OpenSSL/ \
		http://ftp.wayne.edu/pub/openssl/source/ \
		http://www.binarycode.org/openssl/source/ \
		ftp://ftp.openssl.org/source/
.else
.  if !empty(OPENSSL_STABLE:M[yY][eE][sS])
DISTNAME=	openssl-${OPENSSL_VERS:C/[a-z]$//}-stable-SNAP-${OPENSSL_SNAPSHOT}
PKGNAME=	openssl-${OPENSSL_VERS}beta${OPENSSL_SNAPSHOT}
MASTER_SITES=	ftp://ftp.openssl.org/snapshot/
.  else
DISTNAME=	openssl-SNAP-${OPENSSL_SNAPSHOT}
PKGNAME=	openssl-${OPENSSL_VERS}alpha${OPENSSL_SNAPSHOT}
MASTER_SITES=	ftp://ftp.openssl.org/snapshot/
.  endif
.endif

SVR4_PKGNAME=	ossl
CATEGORIES=	security
MAINTAINER=	jlam@pkgsrc.org
HOMEPAGE=	http://www.openssl.org/
COMMENT=	Secure Socket Layer and cryptographic library

CONFLICTS=	SSLeay-[0-9]* ssleay-[0-9]*

CRYPTO=		yes

PKG_INSTALLATION_TYPES=	overwrite pkgviews

.include "../../mk/bsd.prefs.mk"
.include "../../mk/compiler.mk"

USE_PKGINSTALL=		yes
USE_TOOLS+=		gmake perl
TEST_TARGET=		tests

HAS_CONFIGURE=		yes
CONFIGURE_SCRIPT=	./config
CONFIGURE_ARGS+=	--prefix=${PREFIX:Q}
CONFIGURE_ARGS+=	--openssldir=${PKG_SYSCONFDIR:Q}
CONFIGURE_ARGS+=	shared

.if ${OPSYS} == "SunOS" && ${MACHINE_ARCH} == "sparc"
CONFIGURE_SCRIPT=	./Configure
.  if !empty(CC_VERSION:Mgcc*)
CONFIGURE_ARGS+=	solaris-${SPARC_TARGET_ARCH}-gcc
.  else
CONFIGURE_ARGS+=	solaris-${SPARC_TARGET_ARCH}-cc
.  endif
.elif ${OPSYS} == "IRIX"
CONFIGURE_ARGS+=	no-asm
.  if ${ABI} == "64"
CONFIGURE_SCRIPT=	./Configure
CONFIGURE_ARGS+=	irix64-mips4-cc
.  endif
.endif

.include "../../security/openssl/options.mk"

CONFIGURE_ARGS+=	${CFLAGS} ${LDFLAGS}
CONFIGURE_ENV+=		PERL=${PERL5:Q}

PLIST_OPSYS=		${PKGDIR}/PLIST.${LOWER_OPSYS:C/([.0-9]*)$//}
.if exists(${PLIST_OPSYS})
PLIST_SHLIB=		${PLIST_OPSYS}
.else
PLIST_SHLIB=		${PKGDIR}/PLIST.shlib
.endif
PLIST_SRC=		${PLIST_SHLIB}
PLIST_SRC+=		${PKGDIR}/PLIST.common
PLIST_SUBST+=		SHLIB_VERSION=${OPENSSL_VERS:C/[^0-9]*$//}
PLIST_SUBST+=		SHLIB_MAJOR=${OPENSSL_VERS:C/\..*$//}

.if ${OPSYS} == "NetBSD"
PKG_SYSCONFDIR.openssl?=	/etc/openssl
.endif

PKG_SYSCONFSUBDIR=	openssl
CONF_FILES=		${PREFIX}/share/examples/openssl/openssl.cnf	\
			${PKG_SYSCONFDIR}/openssl.cnf
OWN_DIRS=		${PKG_SYSCONFDIR}/certs ${PKG_SYSCONFDIR}/private

# Some shells don't accept empty word lists in for loops.  For those
# Makefiles where this occurs, edit the file so that we avoid running
# the loop.
#
# Also, fix the path to perl in various scripts.
#
pre-configure:
	cd ${WRKSRC};							\
	for file in fips/*/Makefile; do					\
		if ${GREP} "^EXHEADER=[ 	]*$$" $$file >/dev/null; then \
			${ECHO} "Fixing 'install' target in $$file.";	\
			${MV} -f $$file $$file.preawk;			\
			${AWK} '/^install:/ { printf "install:\n\nnot-install:\n"; next } { print }' \
				$$file.preawk > $$file;			\
		fi;							\
	done
	cd ${WRKSRC} && ${PERL5} util/perlpath.pl ${PERL5}

.include  "../../mk/bsd.pkg.mk"