Date: Fri, 28 Jan 2000 02:24:42 -0800 From: Jeremy Lea <reg@FreeBSD.org> To: Kris Kennaway <kris@hub.freebsd.org> Cc: ports@FreeBSD.org Subject: Re: USE_OPENSSL patch Message-ID: <20000128022442.M10368@shale.csir.co.za> In-Reply-To: <Pine.BSF.4.21.0001280030490.22749-100000@hub.freebsd.org>; from kris@hub.FreeBSD.ORG on Fri, Jan 28, 2000 at 12:39:25AM -0800 References: <Pine.BSF.4.21.0001280030490.22749-100000@hub.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi, On Fri, Jan 28, 2000 at 12:39:25AM -0800, Kris Kennaway wrote: > --- Mk/bsd.port.mk 2000/01/21 11:08:06 1.326 > +++ Mk/bsd.port.mk 2000/01/28 07:03:11 > @@ -571,6 +571,42 @@ > PREFIX?= ${LOCALBASE} > .endif > > +.if defined(USE_OPENSSL) > +.if ${OSVERSION} >= 400014 && exists(/usr/lib/libcrypto.a) > +.if ${USE_OPENSSL} == RSA > +_HASRSA= "`/usr/bin/nm /usr/lib/libcrypto.a | /usr/bin/grep RSA_free`" > +.if empty(_HASRSA) > +.BEGIN: > + @${ECHO} "This port requires RSA crypto, which is not present in your" > + @${ECHO} "version of OpenSSL. Please see Chapter XX in the FAQ for" > + @${ECHO} "a description of the problem and alternative solutions." > + @${FALSE} > +.elif defined(USA_RESIDENT) && ${USA_RESIDENT} == YES > +LIB_DEPENDS+= rsaref.2:${PORTSDIR}/security/rsaref > +# We set this so ports can decide whether or not to link against librsaref > +# and libRSAglue > +OPENSSL_RSAREF= yes > +.endif > +.endif > +OPENSSLBASE= /usr > +OPENSSLDIR= /etc/ssl > +# OpenSSL in the base system doesn't include IDEA for patent reasons. > +OPENSSL_IDEA= no > +# XXX Won't always work > +CFLAGS+= -DNO_IDEA > +MAKE_ARGS+= CFLAGS="${CFLAGS}" > +.else > +LIB_DEPENDS+= crypto.1:${PORTSDIR}/security/openssl > +OPENSSLBASE?= ${LOCALBASE} > +OPENSSLDIR?= ${OPENSSLBASE}/openssl > +.endif > +OPENSSLLIB= ${OPENSSLBASE}/lib > +OPENSSLINC= ${OPENSSLBASE}/include > +MAKE_ENV+= OPENSSLLIB=${OPENSSLLIB} OPENSSLINC=${OPENSSLINC} \ > + OPENSSLBASE=${OPENSSLBASE} OPENSSLDIR=${OPENSSLDIR} > +RESTRICTED= "Contains cryptography." > +.endif I thought I'd sent this to you, but I've been doing to many things lately and I must have forgotten. We also need to set OPENSSL_RSAREF for the case where we're using the openssl port. Either that or my pre-openssl current is broken... .else +.if defined(USA_RESIDENT) && ${USA_RESIDENT} == YES +LIB_DEPENDS+= rsaref.2:${PORTSDIR}/security/rsaref +# We set this so ports can decide whether or not to link against librsaref +# and libRSAglue +OPENSSL_RSAREF= yes +.endif LIB_DEPENDS+= crypto.1:${PORTSDIR}/security/openssl Regards, -Jeremy -- FreeBSD - Because the best things in life are free... http://www.freebsd.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000128022442.M10368>