101 lines
3.1 KiB
Makefile
101 lines
3.1 KiB
Makefile
# $NetBSD: Makefile,v 1.21 2007/01/21 10:49:57 wiz Exp $
|
|
|
|
DISTNAME= nss-3.11.4
|
|
CATEGORIES= security
|
|
MASTER_SITES= http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/NSS_3_11_4_RTM/src/ \
|
|
ftp://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/NSS_3_11_4_RTM/src/
|
|
|
|
MAINTAINER= mjl@luckie.org.nz
|
|
HOMEPAGE= http://www.mozilla.org/projects/security/pki/nss/
|
|
COMMENT= Libraries to support development of security-enabled applications
|
|
|
|
BUILD_DEPENDS+= zip>=2.3:../../archivers/zip
|
|
|
|
BUILD_DIRS= mozilla/security/nss
|
|
|
|
USE_TOOLS+= gmake perl
|
|
DIST= ${WRKSRC}/mozilla/dist
|
|
BUILD_TARGET= nss_build_all
|
|
MAKE_ENV+= LD_LIBS="-L${BUILDLINK_PREFIX.nspr}/lib/nspr ${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.nspr}/lib/nspr ${COMPILER_RPATH_FLAG}${LOCALBASE}/lib/nss"
|
|
MAKE_ENV+= LIBRUNPATH=${PREFIX}/lib BUILD_OPT=1
|
|
|
|
.include "../../mk/bsd.prefs.mk"
|
|
|
|
.if ${OBJECT_FMT} == "ELF"
|
|
SO_SUFFIX= so
|
|
.elif ${OBJECT_FMT} == "Mach-O"
|
|
SO_SUFFIX= dylib
|
|
.else
|
|
SO_SUFFIX= so.1.0
|
|
.endif
|
|
PLIST_SUBST+= SO_SUFFIX=${SO_SUFFIX:Q}
|
|
|
|
.if ${OPSYS} == "SunOS" && ${PKGSRC_COMPILER} == "gcc"
|
|
MAKEFLAGS+= NS_USE_GCC=YES
|
|
.endif
|
|
|
|
.if ${OPSYS} == "NetBSD" || ${OPSYS} == "FreeBSD" || ${OPSYS} == "DragonFly"
|
|
NSS_OBJ_DIR= ${OPSYS}${OS_VERSION}_OPT.OBJ
|
|
.elif ${OPSYS} == "SunOS"
|
|
. if ${PKGSRC_COMPILER} == "gcc"
|
|
NSS_OBJ_DIR= ${OPSYS}${OS_VERSION}_gcc_OPT.OBJ
|
|
. else
|
|
NSS_OBJ_DIR= ${OPSYS}${OS_VERSION}_OPT.OBJ
|
|
. endif
|
|
|
|
# on solaris/sparc, we get a different set of libs.
|
|
# How about NetBSD/sparc and sparc64?
|
|
. if ${MACHINE_ARCH} == "sparc"
|
|
SUNOS_TRUE=
|
|
SUNOS_FALSE= "@comment "
|
|
. endif
|
|
|
|
.elif ${OPSYS} == "Linux"
|
|
NSS_SHORT_OS_VERSION!= echo ${OS_VERSION} | ${SED} -e 's/^\([[:digit:]]\.[[:digit:]]\)\..*$$/\1/'
|
|
. if ${MACHINE_ARCH} == "i386"
|
|
NSS_MACHINE_ARCH= _x86
|
|
. elif ${MACHINE_ARCH} == "parisc" || ${MACHINE_ARCH} == "parisc64"
|
|
NSS_MACHINE_ARCH= _hppa
|
|
. elif ${MACHINE_ARCH} == "sparc64"
|
|
NSS_MACHINE_ARCH= _sparc
|
|
. else
|
|
NSS_MACHINE_ARCH= _${MACHINE_ARCH}
|
|
. endif
|
|
NSS_OBJ_DIR= ${OPSYS}${NSS_SHORT_OS_VERSION}${NSS_MACHINE_ARCH}_glibc_PTH_OPT.OBJ
|
|
.endif
|
|
|
|
SUNOS_TRUE?= "@comment "
|
|
SUNOS_FALSE?=
|
|
PLIST_SUBST+= SUNOS_TRUE=${SUNOS_TRUE}
|
|
PLIST_SUBST+= SUNOS_FALSE=${SUNOS_FALSE}
|
|
|
|
NSS_OBJ_DIR?= ${OPSYS}${OS_VERSION}_OPT.OBJ
|
|
|
|
pre-configure:
|
|
${CP} ${FILESDIR}/DragonFly.mk \
|
|
${WRKSRC}/mozilla/security/coreconf/
|
|
|
|
do-install:
|
|
${INSTALL_DATA_DIR} ${PREFIX}/include/nss
|
|
${INSTALL_DATA_DIR} ${PREFIX}/lib/nss
|
|
(cd ${DIST}/public && ${PAX} -Lrwpe . ${PREFIX}/include/nss/ )
|
|
(cd ${DIST}/${NSS_OBJ_DIR}/lib && \
|
|
${PAX} -Lrwpe *.${SO_SUFFIX} ${PREFIX}/lib/nss/ )
|
|
set -e; \
|
|
{ ${ECHO} "Name: NSS"; \
|
|
${ECHO} "Description: Mozilla Network Security Services"; \
|
|
${ECHO} "Version: ${PKGVERSION}"; \
|
|
${ECHO} "Cflags: -I${PREFIX}/include/nss"; \
|
|
${ECHO} "Libs: -L${PREFIX}/lib/nss" \
|
|
"${COMPILER_RPATH_FLAG}${PREFIX}/lib/nss" \
|
|
"-lnss3 -lsmime3 -lssl3 -lsoftokn3 "${BUILDLINK_LIBS.pthread:Q}; \
|
|
} >${PREFIX}/lib/pkgconfig/nss.pc
|
|
|
|
post-install:
|
|
cd ${PREFIX}/include/nss && ${CHMOD} ${SHAREMODE} nss/*.h dbm/*.h nss/*.api
|
|
|
|
BUILDLINK_API_DEPENDS.nspr+= nspr>=4.4.1nb2
|
|
|
|
.include "../../devel/nspr/buildlink3.mk"
|
|
.include "../../mk/pthread.buildlink3.mk"
|
|
.include "../../mk/bsd.pkg.mk"
|