Changeset View
Standalone View
security/openssl-devel/Makefile
# Created by: Dirk Froemberg <dirk@FreeBSD.org> | # Created by: Bernard Spil <brnrd@FreeBSD.org> | ||||
koobs: Revert, this is based on (and copied from) another port. Its heritage is importante :) | |||||
Done Inline ActionsNot done koobs: Not done | |||||
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= openssl | PORTNAME= openssl | ||||
PORTVERSION= 1.0.2 | |||||
DISTVERSIONSUFFIX= f | |||||
PORTREVISION= 8 | |||||
CATEGORIES= security devel | CATEGORIES= security devel | ||||
Done Inline ActionsSure you dont want this to be DISTVERSION=1.1.0-pre3 ? To test varioust versions against each other, use pkg version -t <ver1> <ver2> to ensure that future versions will be > the current version koobs: Sure you dont want this to be `DISTVERSION=1.1.0-pre3` ?
To test varioust versions against… | |||||
Not Done Inline Actionsmake -V PKGNAME brnrd: make -V PKGNAME
pkg version -t openssl-devel-1.1.0.a openssl-devel-1.1.0
Handbook Table 5.1… | |||||
Done Inline ActionsAgain why not DISTVERSIONSUFFIX=-pre3 here, precluding the need for DISTNAME override? koobs: Again why not DISTVERSIONSUFFIX=-pre3 here, precluding the need for DISTNAME override? | |||||
Not Done Inline ActionsAccording to the Package Naming Examples an alpha suffix translates into .a and stings like alpha, beta and rc are not allowed. The OpenSSL project labels these -pre releases as alpha release. I will change this into 1.1.0.p3 as per the -version.numbers specification and pkg version tests
$ pkg version -t pkg version -t openssl-devel-1.1.0.p3 openssl-devel-1.1.0.b2 < $ pkg version -t pkg version -t openssl-devel-1.1.0.p3 openssl-devel-1.1.0.r1` < DISTNAME would resolve to openssl-1.1.0.p3 so I had to resort to DISTVERSION= 1.1.0-pre3. brnrd: According to the [[ https://www.freebsd.org/doc/en/books/porters-handbook/book.html#idp58683728… | |||||
Done Inline ActionsLet DISTVERSION do the correct PORTVERSION derivation automatically. This should be DISTVERSION=1.1.0-pre3 koobs: Let DISTVERSION do the correct PORTVERSION derivation automatically. This should be… | |||||
MASTER_SITES= http://www.openssl.org/source/ \ | MASTER_SITES= https://www.openssl.org/source/ \ | ||||
Done Inline Actions
koobs: * If when this becomes release, what will the port be named?
* Will multiple openssl… | |||||
Not Done Inline ActionsOnce 1.1 is released, the security/openssl port will take over until OpenSSL starts a new devel version. @dinoex already questioned if we want this port at all. brnrd: Once 1.1 is released, the security/openssl port will take over until OpenSSL starts a new devel… | |||||
Done Inline ActionsIs there an SSL/HTTPS master_sites? koobs: Is there an SSL/HTTPS master_sites? | |||||
Not Done Inline ActionsOnly one. And no info on mirroring process. Therefore must assume all mirrors are updated unsafely and we should rely on the SHA256 hash and tarball size. brnrd: Only one. And no info on mirroring process. Therefore must assume all mirrors are updated… | |||||
ftp://ftp.openssl.org/source/ \ | ftp://ftp.openssl.org/source/ \ | ||||
ftp://ftp.cert.dfn.de/pub/tools/net/openssl/source/ | ftp://ftp.cert.dfn.de/pub/tools/net/openssl/source/ | ||||
DIST_SUBDIR= ${DISTNAME} | PKGNAMESUFFIX= -devel | ||||
DISTVERSION= 1.1.0-pre3 | |||||
Done Inline ActionsThis wont be needed when you use DISTVERSION above koobs: This wont be needed when you use DISTVERSION above | |||||
Done Inline ActionsI believe this will make portlint cry (due to ordering). DISTVERSION should be placed where PORTVERSION normally is koobs: I believe this will make portlint cry (due to ordering). DISTVERSION should be placed where… | |||||
Not Done Inline ActionsFixed portlint FATAL by moving brnrd: Fixed portlint FATAL by moving | |||||
Done Inline ActionsNot done, cant see this changed in the diff koobs: Not done, cant see this changed in the diff | |||||
MAINTAINER= dinoex@FreeBSD.org | MAINTAINER= brnrd@FreeBSD.org | ||||
Done Inline ActionsIs Dirk happy to maintain this? If not, set MAINTAINER to you koobs: Is Dirk happy to maintain this? If not, set MAINTAINER to you | |||||
Not Done Inline ActionsMy bad. brnrd: My bad.
Should I also update Created by? (line 1) | |||||
COMMENT= SSL and crypto library | COMMENT= SSL and crypto library (1.1-Alpha) | ||||
Done Inline ActionsAdd a relevant (suffix) to COMMENT (1.1.x) or similar so its easily distinguishable/obvious in pkg info and other list output koobs: Add a relevant `(suffix)` to COMMENT `(1.1.x)` or similar so its easily distinguishable/obvious… | |||||
Not Done Inline ActionsCorrected brnrd: Corrected | |||||
Done Inline ActionsI dont think the alpha designation is needed here. Just that its a different release series than security/openssl. I was thinking COMMENT= SSL and crypto library (1.1.x) koobs: I dont think the alpha designation is needed here. Just that its a different release series… | |||||
Done Inline ActionsI think 1.1.x is better here, as the alpha will at some point become beta -> rc -> release, and we ought not have to change COMMENT each time. koobs: I think `1.1.x` is better here, as the alpha will at some point become beta -> rc -> release… | |||||
Not Done Inline ActionsAgree! brnrd: Agree! | |||||
Done Inline ActionsNot done, cant see this in the diff koobs: Not done, cant see this in the diff | |||||
.ifdef USE_OPENSSL | |||||
.error You have `USE_OPENSSL' variable defined either in environment or in make(1) arguments. Please undefine and try again. | |||||
.endif | |||||
CONFLICTS?= libressl-* | |||||
LICENSE= OpenSSL | LICENSE= OpenSSL | ||||
Done Inline ActionsThis needs updating unless it doesn't also conflict with security/openssl? koobs: This needs updating unless it doesn't also conflict with `security/openssl`? | |||||
Not Done Inline ActionsIt does, and added first digit check (for lint). brnrd: It does, and added first digit check (for lint). | |||||
Done Inline Actions
koobs: * Is this still necessary? Why?
* Can it be moved to bsd.openssl.mk?
| |||||
Not Done Inline ActionsTested with make -DUSE_OPENSSL, obviously superfluous brnrd: Tested with make -DUSE_OPENSSL, obviously superfluous | |||||
LICENSE_FILE= ${WRKSRC}/LICENSE | LICENSE_FILE= ${WRKSRC}/LICENSE | ||||
OPTIONS_DEFINE= SHARED THREADS I386 SSE2 ASM PADLOCK ZLIB GMP SCTP SSL2 SSL3 RFC3779 MD2 RC5 EXPCIPHERS DOCS MAN3 | CONFLICTS= libressl-[0-9]* openssl-[0-9]* | ||||
OPTIONS_DEFAULT=SHARED THREADS SSE2 SCTP SSL2 SSL3 MD2 MAN3 | |||||
OPTIONS_GROUP= CIPHERS HASHES OPTIMIZATIONS PROTOCOLS | |||||
OPTIONS_GROUP_CIPHERS= IDEA JPAKE RC2 RC4 RC5 | |||||
OPTIONS_GROUP_HASHES= MD2 MD4 MDC2 MD_GHOST94 RMD160 | |||||
OPTIONS_GROUP_OPTIMIZATIONS= ASM I386 SSE2 | |||||
OPTIONS_GROUP_PROTOCOLS= NEXTPROTONEG SCTP SSL3 | |||||
OPTIONS_DEFINE= SHARED THREADS ZLIB RFC3779 MAN3 | |||||
OPTIONS_DEFAULT= ASM MAN3 RMD160 SCTP SHARED SSE2 THREADS | |||||
Done Inline ActionsNot a fan of the OPTIMS and PROTOS names Maybe OPTIMIZE and PROTOCOLS koobs: Not a fan of the OPTIMS and PROTOS names
Maybe `OPTIMIZE` and `PROTOCOLS` | |||||
Not Done Inline ActionsThat's more correct. Broke indentation so shortened them. OPTIMIZE or OPTIMISE... (en_US vs en_UK iirc) ? :D brnrd: That's more correct. Broke indentation so shortened them.
OPTIMIZE or OPTIMISE... (en_US vs… | |||||
Done Inline ActionsUS koobs: US | |||||
.for a in amd64 ia64 | .for a in amd64 ia64 | ||||
Not Done Inline ActionsOptimiZe is US brnrd: OptimiZe is US | |||||
Done Inline ActionsI would still use the shorter version OPTIMIZE (but your call) koobs: I would still use the shorter version OPTIMIZE (but your call) | |||||
Done Inline ActionsOK as is brnrd: OK as is | |||||
OPTIONS_DEFINE_${a}= EC | OPTIONS_GROUP_OPTIMIZATIONS_${a}= EC | ||||
OPTIONS_DEFAULT_${a}= EC | OPTIONS_DEFAULT_${a}= EC | ||||
.endfor | .endfor | ||||
TARGET_ARCH?= ${MACHINE_ARCH} | TARGET_ARCH?= ${MACHINE_ARCH} | ||||
.if ${TARGET_ARCH} == "mips64el" | .if ${TARGET_ARCH} == "mips64el" | ||||
OPTIONS_DEFINE_mips= EC | OPTIONS_GROUP_OPTIMIZATIONS+= EC | ||||
OPTIONS_DEFAULT_mips= EC | OPTIONS_DEFAULT+= EC | ||||
.endif | .endif | ||||
ASM_DESC= Assembler code | |||||
CIPHERS_DESC= Cipher Suite Support | |||||
Done Inline Actions"Cipher Suite Support" koobs: `"Cipher Suite Support"` | |||||
EC_DESC= NIST elliptic curves | |||||
HASHES_DESC= Hash Function Support | |||||
Done Inline Actions"Hash Function Support" koobs: `"Hash Function Support"` | |||||
I386_DESC= i386 (instead of i486+) | |||||
IDEA_DESC= IDEA | |||||
JPAKE_DESC= J-PAKE (experimental) | |||||
MAN3_DESC= Install API manpages (section 3) | |||||
MD2_DESC= MD2 (obsolete) | |||||
MD4_DESC= MD4 (unsafe) | |||||
MDC2_DESC= MDC-2 | |||||
MD_GHOST94_DESC= GHOST94 (obscure) | |||||
NEXTPROTONEG_DESC= Next Protocol Negotiation (SPDY) | |||||
OPTIMIZATIONS_DESC= Optimizations | |||||
PROTOCOLS_DESC= Protocols Support | |||||
Done Inline Actions"Protocol Support" koobs: `"Protocol Support"` | |||||
RC2_DESC= RC2 (unsafe) | |||||
RC4_DESC= RC4 (unsafe) | |||||
RC5_DESC= RC5 (patented) | |||||
RMD160_DESC= RIPEMD-160 | |||||
RFC3779_DESC= RFC3779 support (BGP) | |||||
SCTP_DESC= SCTP (Stream Control Transmission) | |||||
SHARED_DESC= Build shared libraries | |||||
SSE2_DESC= Runtime SSE2 detection | |||||
SSL3_DESC= SSLv3 | |||||
ZLIB_DESC= zlib compression support | |||||
Done Inline ActionsClean this up (less verbose). Eg:
koobs: Clean this up (less verbose). Eg:
* Remove "support" and "hash" where you can (since they're… | |||||
Not Done Inline ActionsFixed all the DESC items brnrd: Fixed all the DESC items | |||||
NO_OPTIONS_SORT=yes | NO_OPTIONS_SORT=yes | ||||
OPTIONS_SUB= yes | OPTIONS_SUB= yes | ||||
I386_DESC?= Optimize for i386 (instead of i486+) | HAS_CONFIGURE= yes | ||||
SSE2_DESC?= runtime SSE2 detection | CONFIGURE_SCRIPT= config | ||||
ASM_DESC?= optimized Assembler code | |||||
PADLOCK_DESC?= VIA Padlock support | |||||
SHARED_DESC?= build of shared libs | |||||
ZLIB_DESC?= zlib compression support | |||||
GMP_DESC?= gmp support (LGPLv3) | |||||
SCTP_DESC?= SCTP protocol support | |||||
SSL2_DESC?= SSLv2 protocol support | |||||
SSL3_DESC?= SSLv3 protocol support | |||||
RFC3779_DESC?= RFC3779 support (BGP) | |||||
MD2_DESC?= MD2 hash (obsolete) | |||||
RC5_DESC?= RC5 cipher (patented) | |||||
EXPCIPHERS_DESC?= Include experimental ciphers | |||||
EC_DESC?= Optimize NIST elliptic curves | |||||
MAN3_DESC?= Install API manpages (section 3) | |||||
GMP_LIB_DEPENDS= libgmp.so:${PORTSDIR}/math/gmp | |||||
MAKE_JOBS_UNSAFE= yes | MAKE_JOBS_UNSAFE= yes | ||||
NOPRECIOUSMAKEVARS= Too many _MLINKS for fetch | NOPRECIOUSMAKEVARS= Too many _MLINKS for fetch | ||||
NOPRECIOUSSOFTMAKEVARS= Too many _MLINKS for fetch | NOPRECIOUSSOFTMAKEVARS= Too many _MLINKS for fetch | ||||
USES= perl5 cpe | USES= perl5 cpe | ||||
USE_PERL5= build | USE_PERL5= build | ||||
MAKE_ARGS+= WHOLE_ARCHIVE_FLAG=--whole-archive | MAKE_ARGS+= WHOLE_ARCHIVE_FLAG=--whole-archive | ||||
MAKE_ENV+= LIBRPATH="${PREFIX}/lib" GREP_OPTIONS= | MAKE_ENV+= LIBRPATH="${PREFIX}/lib" GREP_OPTIONS= | ||||
SUB_FILES= pkg-message | SUB_FILES= pkg-message | ||||
TEST_TARGET= test | |||||
CPE_VERSION= ${PORTVERSION}${DISTVERSIONSUFFIX} | CPE_VERSION= ${DISTVERSION} | ||||
.for _option in asm idea md2 md4 mdc2 md_ghost94 nextprotoneg rc5 rfc3779 rmd160 sctp sse2 ssl3 threads | |||||
${_option:tu}_CONFIGURE_ON= enable-${_option} | |||||
${_option:tu}_CONFIGURE_OFF= no-${_option} | |||||
.endfor | |||||
ASM_NOT_FOR_ARCHS= sparc6 | |||||
EC_CONFIGURE_ON= enable-ec_nistp_64_gcc_128 | |||||
EC_CONFIGURE_OFF= no-ec_nistp_64_gcc_128 | |||||
SHARED_CONFIGURE_ON= shared | |||||
SHARED_MAKE_ENV= SHLIBVER=${OPENSSL_SHLIBVER} | |||||
SHARED_PLIST_SUB= SHLIBVER=${OPENSSL_SHLIBVER} | |||||
SHARED_USE_LDCONFIG= yes | |||||
SSL3_CONFIGURE_OFF= no-ssl3-method | |||||
.include <bsd.port.pre.mk> | .include <bsd.port.pre.mk> | ||||
.if ${PREFIX} == /usr | .if ${PREFIX} == /usr | ||||
IGNORE= the OpenSSL port can not be installed over the base version | IGNORE= the OpenSSL port can not be installed over the base version | ||||
.endif | .endif | ||||
OPENSSLDIR?= ${PREFIX}/openssl | OPENSSLDIR?= ${PREFIX}/openssl | ||||
PLIST_SUB+= OPENSSLDIR=${OPENSSLDIR:S=^${PREFIX}/==} | PLIST_SUB+= OPENSSLDIR=${OPENSSLDIR:S=^${PREFIX}/==} | ||||
CONFIGURE_ARGS+= --openssldir=${OPENSSLDIR} -L${PREFIX}/lib | |||||
Done Inline ActionsI don't believe reason for global -L${PREFIX}/lib was answered from previous review inline comment koobs: I don't believe reason for global `-L${PREFIX}/lib` was answered from previous review inline… | |||||
Not Done Inline ActionsWithout -L${PREFIX}/lib the Configure script will not correctly set EX_LIBS for compilation leading to issues during linking brnrd: Without `-L${PREFIX}/lib` the `Configure` script will not correctly set EX_LIBS for compilation… | |||||
Done Inline ActionsBut what needs to be linked from LOCALBASE exactly? Further, shouldn't USES=localbase be used if its required? koobs: But what needs to be linked from LOCALBASE exactly?
Further, shouldn't `USES=localbase` be… | |||||
Done Inline ActionsRemove commented line, or fix koobs: Remove commented line, or fix | |||||
OPENSSL_BASE_SONAME!= readlink ${DESTDIR}/usr/lib/libcrypto.so || true | OPENSSL_BASE_SONAME!= readlink ${DESTDIR}/usr/lib/libcrypto.so || true | ||||
OPENSSL_SHLIBVER_BASE= ${OPENSSL_BASE_SONAME:E} | OPENSSL_SHLIBVER_BASE= ${OPENSSL_BASE_SONAME:E} | ||||
OPENSSL_BASE_SOPATH= ${OPENSSL_BASE_SONAME:H} | OPENSSL_BASE_SOPATH= ${OPENSSL_BASE_SONAME:H} | ||||
OPENSSL_SHLIBVER?= 8 | OPENSSL_SHLIBVER?= 8 | ||||
.if ${PORT_OPTIONS:MI386} | |||||
.if ${ARCH} == "i386" | .if ${ARCH} == "i386" | ||||
EXTRACONFIGURE+= 386 | I386_CONFIGURE_ON= 386 | ||||
Done Inline ActionsThis doesn't appear to be a --configure-argument Why was CONFIGURE_ARGS used to replace EXTRACONFIGURE in the original port? CONFIGURE_ARGS is a framework variable. It should be obvious that the args one needs to pass to the later ./config call later on are not *actually* CONFIGURE_ARGS, but special for this port. Use of CONFIGURE_ARGS here is confusing (and more so for future readers) koobs: This doesn't appear to be a --configure-argument
Why was CONFIGURE_ARGS used to replace… | |||||
Not Done Inline ActionsUsing CONFIGURE_ARGS makes the Makefile more legible and a lot smaller. brnrd: Using CONFIGURE_ARGS makes the Makefile more legible and a lot smaller.
There's no replacement… | |||||
Done Inline ActionsIs this the only unsupported FreeBSD arch when using ASM? How was this determined? Also, use OPT_VARS=NOT_FOR_ARCHS=<value> and move it to where other ASM_* options are The if conditional block is now no longer needed for generic variables koobs: Is this the only unsupported FreeBSD arch when using ASM? How was this determined?
Also, use… | |||||
Not Done Inline ActionsCorrected brnrd: Corrected | |||||
Done Inline ActionsAll of these can be converted to OPT_VARS=VARIABLE[+]=<value> koobs: All of these can be converted to `OPT_VARS=VARIABLE[+]=<value>` | |||||
Not Done Inline ActionsMissed this one! Done. brnrd: Missed this one! Done. | |||||
Done Inline ActionsDon't need .if/.endif block surrounding entries when using options helpers koobs: Don't need .if/.endif block surrounding entries when using options helpers | |||||
Not Done Inline ActionsThese are 2 separate tests. This is to make sure that 386 is added to CONFIGURE_ARCHS only if both the OPTION is set and the ARCH is 386. (386 vs I386)) brnrd: These are 2 separate tests. This is to make sure that 386 is added to CONFIGURE_ARCHS //only//… | |||||
Done Inline ActionsBased on that explanation, I think this should be: i386_OPTIONS_DEFINE=I386 ... I386_CONFIGURE_ON=386 Relevant snippet from bsd.options.mk:
koobs: Based on that explanation, I think this should be:
```
i386_OPTIONS_DEFINE=I386
... | |||||
Done Inline ActionsSee prior diff comment comment (re ARCH_OPTIONS_DEFINE) koobs: See prior diff comment comment (re ARCH_OPTIONS_DEFINE) | |||||
.endif | .endif | ||||
.endif | |||||
.if empty(PORT_OPTIONS:MSSE2) | |||||
# disable runtime SSE2 detection | |||||
EXTRACONFIGURE+= no-sse2 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MASM} | |||||
BROKEN_sparc64= option ASM generates illegal instructions | |||||
EXTRACONFIGURE+= enable-asm | |||||
.else | |||||
EXTRACONFIGURE+= no-asm | |||||
.endif | |||||
.if ${PORT_OPTIONS:MTHREADS} | |||||
EXTRACONFIGURE+= threads | |||||
.else | |||||
EXTRACONFIGURE+= no-threads | |||||
.endif | |||||
.if ${PORT_OPTIONS:MSHARED} | |||||
EXTRACONFIGURE+= shared | |||||
MAKE_ENV+= SHLIBVER=${OPENSSL_SHLIBVER} | |||||
PLIST_SUB+= SHLIBVER=${OPENSSL_SHLIBVER} | |||||
USE_LDCONFIG= yes | |||||
.endif | |||||
.if ${PORT_OPTIONS:MZLIB} | |||||
EXTRACONFIGURE+= zlib zlib-dynamic | |||||
.else | |||||
EXTRACONFIGURE+= no-zlib no-zlib-dynamic | |||||
.endif | |||||
.if ${PORT_OPTIONS:MSCTP} | |||||
EXTRACONFIGURE+= sctp | |||||
.else | |||||
EXTRACONFIGURE+= no-sctp | |||||
.endif | |||||
.if ${PORT_OPTIONS:MSSL2} | |||||
EXTRACONFIGURE+= enable-ssl2 | |||||
.else | |||||
EXTRACONFIGURE+= no-ssl2 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MSSL3} | |||||
EXTRACONFIGURE+= enable-ssl3 | |||||
.else | |||||
EXTRACONFIGURE+= no-ssl3 no-ssl3-method | |||||
.endif | |||||
.if ${PORT_OPTIONS:MMD2} | |||||
EXTRACONFIGURE+= enable-md2 | |||||
.else | |||||
EXTRACONFIGURE+= no-md2 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MRC5} | |||||
EXTRACONFIGURE+= enable-rc5 | |||||
.else | |||||
EXTRACONFIGURE+= no-rc5 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MPADLOCK} | |||||
PATCH_DIST_STRIP= -p1 | |||||
PATCH_SITES+= http://git.alpinelinux.org/cgit/aports/plain/main/openssl/:padlock | |||||
PATCHFILES+= 1001-crypto-hmac-support-EVP_MD_CTX_FLAG_ONESHOT-and-set-.patch:padlock \ | |||||
1002-backport-changes-from-upstream-padlock-module.patch:padlock \ | |||||
1003-engines-e_padlock-implement-sha1-sha224-sha256-accel.patch:padlock \ | |||||
1004-crypto-engine-autoload-padlock-dynamic-engine.patch:padlock | |||||
.endif | |||||
.if ${PORT_OPTIONS:MGMP} | |||||
EXTRACONFIGURE+= enable-gmp -I${LOCALBASE}/include | |||||
IGNORE= can not be linked because GMP is LGPLv3 | |||||
.else | |||||
EXTRACONFIGURE+= no-gmp | |||||
.endif | |||||
.if ${PORT_OPTIONS:MRFC3779} | |||||
EXTRACONFIGURE+= enable-rfc3779 | |||||
.else | |||||
EXTRACONFIGURE+= no-rfc3779 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MEC} | |||||
EXTRACONFIGURE+= enable-ec_nistp_64_gcc_128 | |||||
.else | |||||
EXTRACONFIGURE+= no-ec_nistp_64_gcc_128 | |||||
.endif | |||||
.if ${OPENSSL_SHLIBVER_BASE} > ${OPENSSL_SHLIBVER} | .if ${OPENSSL_SHLIBVER_BASE} > ${OPENSSL_SHLIBVER} | ||||
pre-everything:: | pre-everything:: | ||||
@${ECHO_CMD} "#" | @${ECHO_CMD} "#" | ||||
@${ECHO_CMD} "# this ports conflicts with your base system" | @${ECHO_CMD} "# this ports conflicts with your base system" | ||||
@${ECHO_CMD} "# please undefine OPENSSL_OVERWRITE_PORT" | @${ECHO_CMD} "# please undefine OPENSSL_OVERWRITE_PORT" | ||||
@${ECHO_CMD} "# and use WITH_OPENSSL_BASE=yes instead." | @${ECHO_CMD} "# and use WITH_OPENSSL_BASE=yes instead." | ||||
@${ECHO_CMD} "#" | @${ECHO_CMD} "#" | ||||
@${FALSE} | @${FALSE} | ||||
.endif | .endif | ||||
post-patch: | post-patch: | ||||
${REINPLACE_CMD} -e 's|m4 -B 8192|m4|g' \ | ${REINPLACE_CMD} -e 's|m4 -B 8192|m4|g' \ | ||||
${WRKSRC}/crypto/des/Makefile | ${WRKSRC}/crypto/des/Makefile.in | ||||
${REINPLACE_CMD} -e 's|SHLIB_VERSION_NUMBER "1.0.0"|SHLIB_VERSION_NUMBER "${OPENSSL_SHLIBVER}"|' \ | |||||
${WRKSRC}/crypto/opensslv.h | |||||
${REINPLACE_CMD} -e 's|ERR_R_MALLOC_ERROR|ERR_R_MALLOC_FAILURE|' \ | ${REINPLACE_CMD} -e 's|ERR_R_MALLOC_ERROR|ERR_R_MALLOC_FAILURE|' \ | ||||
${WRKSRC}/crypto/bio/bss_dgram.c | ${WRKSRC}/crypto/bio/bss_dgram.c | ||||
.if ${PORT_OPTIONS:MEXPCIPHERS} | |||||
${REINPLACE_CMD} -e 's|TLS1_ALLOW_EXPERIMENTAL_CIPHERSUITES 0|TLS1_ALLOW_EXPERIMENTAL_CIPHERSUITES 1|' \ | |||||
${WRKSRC}/ssl/tls1.h | |||||
.endif | |||||
do-configure: | post-configure: | ||||
${REINPLACE_CMD} -e "s|options 386|options|" \ | |||||
${WRKSRC}/config | |||||
.if ${PORT_OPTIONS:MTHREADS} | |||||
cd ${WRKSRC} \ | |||||
&& ${SETENV} CC="${CC}" FREEBSDCC="${CC}" CFLAGS="${CFLAGS}" PERL="${PERL}" \ | |||||
./config --prefix=${PREFIX} --openssldir=${OPENSSLDIR} \ | |||||
--install_prefix=${STAGEDIR} \ | |||||
-L${PREFIX}/lib ${EXTRACONFIGURE} | |||||
.else | |||||
cd ${WRKSRC} \ | |||||
&& ${SETENV} CC="${CC}" FREEBSDCC="${CC}" CFLAGS="${CFLAGS}" PERL="${PERL}" \ | |||||
./config --prefix=${PREFIX} --openssldir=${OPENSSLDIR} \ | |||||
--install_prefix=${STAGEDIR} \ | |||||
-L${PREFIX}/lib ${EXTRACONFIGURE} | |||||
.endif | |||||
${REINPLACE_CMD} \ | ${REINPLACE_CMD} \ | ||||
-e 's|^MANDIR=.*$$|MANDIR=$$(PREFIX)/man|' \ | -e 's|^MANDIR=.*$$|MANDIR=$$(PREFIX)/man|' \ | ||||
-e 's|$$(LIBDIR)/pkgconfig|libdata/pkgconfig|g' \ | -e 's|$$(LIBDIR)/pkgconfig|libdata/pkgconfig|g' \ | ||||
-e 's|LIBVERSION=[^ ]* |LIBVERSION=$(OPENSSL_SHLIBVER) |' \ | -e 's|LIBVERSION=[^ ]* |LIBVERSION=$(OPENSSL_SHLIBVER) |' \ | ||||
${WRKSRC}/Makefile | ${WRKSRC}/Makefile | ||||
post-install: | post-install-SHARED-on: | ||||
Done Inline ActionsConvert to options helper target target-OPTION-on koobs: Convert to options helper target `target-OPTION-on` | |||||
Not Done Inline ActionsIs already a no-op, both branches are the same. Fixed accordingly Replaced with HAS_CONFIGURE, CONFIGURE_SCRIPT, USE_PERL5=build,configure, moved Makefile patching to post-configure brnrd: Is already a no-op, both branches are the same. Fixed accordingly
Replaced with HAS_CONFIGURE… | |||||
.if ${PORT_OPTIONS:MSHARED} | |||||
.for i in libcrypto libssl | .for i in libcrypto libssl | ||||
${INSTALL_DATA} ${WRKSRC}/$i.so.${OPENSSL_SHLIBVER} ${STAGEDIR}${PREFIX}/lib | ${INSTALL_DATA} ${WRKSRC}/$i.so.${OPENSSL_SHLIBVER} ${STAGEDIR}${PREFIX}/lib | ||||
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/$i.so.${OPENSSL_SHLIBVER} | |||||
${LN} -sf $i.so.${OPENSSL_SHLIBVER} ${STAGEDIR}${PREFIX}/lib/$i.so | ${LN} -sf $i.so.${OPENSSL_SHLIBVER} ${STAGEDIR}${PREFIX}/lib/$i.so | ||||
.endfor | .endfor | ||||
.endif | .for i in libcapi libdasync libpadlock | ||||
.if empty(PORT_OPTIONS:MMAN3) | ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/engines/${i}.so | ||||
.endfor | |||||
post-install-MAN3-off: | |||||
${RM} -rf ${STAGEDIR}/${PREFIX}/man/man3 | ${RM} -rf ${STAGEDIR}/${PREFIX}/man/man3 | ||||
${REINPLACE_CMD} -e 's|^man/man3/.*||' ${TMPPLIST} | ${REINPLACE_CMD} -e 's|^man/man3/.*||' ${TMPPLIST} | ||||
.endif | |||||
post-install-DOCS-on: | post-install: | ||||
${MKDIR} ${STAGEDIR}${DOCSDIR} | ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/openssl | ||||
${INSTALL_DATA} ${WRKSRC}/doc/openssl.txt ${STAGEDIR}${DOCSDIR}/ | |||||
test: build | |||||
cd ${WRKSRC} && ${MAKE} test | |||||
regression-test: test | |||||
.include <bsd.port.post.mk> | .include <bsd.port.post.mk> |
Revert, this is based on (and copied from) another port. Its heritage is importante :)