diff options
author | Dirk Meyer <dinoex@FreeBSD.org> | 2003-08-30 07:26:04 +0000 |
---|---|---|
committer | Dirk Meyer <dinoex@FreeBSD.org> | 2003-08-30 07:26:04 +0000 |
commit | 8bb2031d2c0be6355104f5cad0e8e0cd55413bf0 (patch) | |
tree | 6c3d3f4a0f64f2b55c4d24b25ce3411316039a32 /Mk/bsd.openssl.mk | |
parent | c8e27ac5dce272b8d05ca7dcb812b7b5830819bd (diff) | |
download | ports-8bb2031d2c0be6355104f5cad0e8e0cd55413bf0.tar.gz ports-8bb2031d2c0be6355104f5cad0e8e0cd55413bf0.zip |
- new option USE_OPENSSL_RPATH
to pass RFLAGS options in CFLAGS,
needed for ports who don't use LDFLAGS
- honor when WITHOUT_OPENSSL is set
PR: 56113
Notes
Notes:
svn path=/head/; revision=88056
Diffstat (limited to 'Mk/bsd.openssl.mk')
-rw-r--r-- | Mk/bsd.openssl.mk | 25 |
1 files changed, 18 insertions, 7 deletions
diff --git a/Mk/bsd.openssl.mk b/Mk/bsd.openssl.mk index a36a309dc937..6ff2e1912e1b 100644 --- a/Mk/bsd.openssl.mk +++ b/Mk/bsd.openssl.mk @@ -2,7 +2,7 @@ # Date created: 31 May 2002 # Whom: dinoex # -# $FreeBSD: /tmp/pcvs/ports/Mk/bsd.openssl.mk,v 1.6 2003-08-27 10:30:40 dinoex Exp $ +# $FreeBSD: /tmp/pcvs/ports/Mk/bsd.openssl.mk,v 1.7 2003-08-30 07:26:04 dinoex Exp $ # # this substitutes USE_OPENSSL=yes # just include this makefile after bsd.ports.pre.mk @@ -13,6 +13,9 @@ # WITH_OPENSSL_PORT=yes - Use the port, even if base if up to date # WITH_OPENSSL_BETA=yes - Use a snapshot of recent openssl # +# USE_OPENSSL_RPATH=yes - pass RFLAGS options in CFLAGS, +# needed for ports who don't use LDFLAGS +# # Overrideable defaults: # # OPENSSL_SHLIBVER= 3 @@ -23,8 +26,10 @@ # OPENSSLDIR - path to openssl # OPENSSLLIB - path to the libs # OPENSSLINC - path to the matching includes +# OPENSSLRPATH - rpath for dynamic linker # # MAKE_ENV - extended with the variables above +# CONFIGURE_ENV - extended with LDFLAGS # LIB_DEPENDS - are added if needed OpenSSL_Include_MAINTAINER= dinoex@FreeBSD.org @@ -92,8 +97,7 @@ OPENSSL_CFLAGS+= -DNO_IDEA .endif MAKE_ARGS+= OPENSSL_CFLAGS="${OPENSSL_CFLAGS}" .endif -CFLAGS+= -Wl,-rpath,/usr/lib:${LOCALBASE}/lib -OPENSSL_LDFLAGS+= -rpath=/usr/lib:${LOCALBASE}/lib +OPENSSLRPATH= /usr/lib:${LOCALBASE}/lib .else @@ -107,15 +111,17 @@ OPENSSL_PORT?= security/openssl .endif OPENSSLDIR= ${OPENSSLBASE}/openssl LIB_DEPENDS+= crypto.${OPENSSL_SHLIBVER}:${PORTSDIR}/${OPENSSL_PORT} -CFLAGS+= -Wl,-rpath,${LOCALBASE}/lib -OPENSSL_LDFLAGS+= -rpath=${LOCALBASE}/lib +OPENSSLRPATH= ${LOCALBASE}/lib .endif OPENSSLLIB= ${OPENSSLBASE}/lib OPENSSLINC= ${OPENSSLBASE}/include -MAKE_ENV+= OPENSSLLIB=${OPENSSLLIB} OPENSSLINC=${OPENSSLINC} \ - OPENSSLBASE=${OPENSSLBASE} OPENSSLDIR=${OPENSSLDIR} + +.if defined(USE_OPENSSL_RPATH) +CFLAGS+= -Wl,-rpath,${OPENSSLRPATH} +.endif +OPENSSL_LDFLAGS+= -rpath=${OPENSSLRPATH} .if defined(LDFLAGS) && !empty(LDFLAGS) LDFLAGS+=${OPENSSL_LDFLAGS} @@ -123,6 +129,11 @@ LDFLAGS+=${OPENSSL_LDFLAGS} LDFLAGS=${OPENSSL_LDFLAGS} .endif +CONFIGURE_ENV+= LDFLAGS="${LDFLAGS}" +MAKE_ENV+= LDFLAGS="${LDFLAGS}" +MAKE_ENV+= OPENSSLLIB=${OPENSSLLIB} OPENSSLINC=${OPENSSLINC} \ + OPENSSLBASE=${OPENSSLBASE} OPENSSLDIR=${OPENSSLDIR} + ### crypto #RESTRICTED= "Contains cryptography." |