Thursday, October 31, 2019

nss: Set BUILD_OPT only when DEBUG is unset

Had this diff laying here ever since requiring a debug build of NSS;
I think BUILD_OPT still turned into `-O2' when I passed `DEBUG=-O0'
and/or stripping symbols in the end; either way it made setting DEBUG
what one would expect.

This does not effect normal builds as DEBUG is unset, so no REVISION
bump.

OK?


Index: security/nss/Makefile
===================================================================
RCS file: /cvs/ports/security/nss/Makefile,v
retrieving revision 1.111
diff -u -p -r1.111 Makefile
--- security/nss/Makefile 23 Oct 2019 19:30:25 -0000 1.111
+++ security/nss/Makefile 23 Oct 2019 22:31:59 -0000
@@ -25,8 +25,7 @@ LIB_DEPENDS= databases/sqlite3 \
devel/nspr>=${NSPR_VERSION}
WANTLIB += c pthread z nspr4 plc4 plds4 sqlite3>=22

-MAKE_ENV= BUILD_OPT=1 \
- LOCALBASE="${LOCALBASE}" \
+MAKE_ENV= LOCALBASE="${LOCALBASE}" \
NSS_SEED_ONLY_DEV_URANDOM=1 \
NSS_ENABLE_ECC=1 \
NSS_ENABLE_TLS_1_3=1 \
@@ -36,6 +35,10 @@ MAKE_ENV= BUILD_OPT=1 \
XCFLAGS="-I${LOCALBASE}/include ${CFLAGS}" \
NSPR_INCLUDE_DIR="${LOCALBASE}/include/nspr" \
NSPR_LIB_DIR="${LOCALBASE}/lib"
+
+.if !defined(DEBUG)
+MAKE_ENV+= BUILD_OPT=1
+.endif

USE_GMAKE= Yes

No comments:

Post a Comment