Annotation of pkgsrc/security/openssl/Makefile, Revision 1.238
1.238 ! wiz 1: # $NetBSD: Makefile,v 1.237 2018/01/02 05:37:23 maya Exp $
1.98 jlam 2:
1.238 ! wiz 3: DISTNAME= openssl-1.0.2o
1.202 adam 4: CATEGORIES= security
1.213 wiz 5: MASTER_SITES= https://www.openssl.org/source/
1.169 wiz 6:
1.115 jlam 7: MAINTAINER= pkgsrc-users@NetBSD.org
1.209 tron 8: HOMEPAGE= https://www.openssl.org/
1.98 jlam 9: COMMENT= Secure Socket Layer and cryptographic library
1.189 wiz 10: LICENSE= openssl
1.1 tv 11:
1.98 jlam 12: CONFLICTS= SSLeay-[0-9]* ssleay-[0-9]*
1.1 tv 13:
1.211 wiz 14: BUILD_DEPENDS+= p5-Perl4-CoreLibs-[0-9]*:../../devel/p5-Perl4-CoreLibs
1.169 wiz 15:
1.185 jperkin 16: USE_GCC_RUNTIME= yes
17:
1.229 marino 18: USE_TOOLS+= fgrep gmake makedepend perl:run
1.216 jperkin 19: BUILD_TARGET= depend all
1.98 jlam 20: TEST_TARGET= tests
1.136 adrianp 21: MAKE_JOBS_SAFE= no
1.98 jlam 22:
23: HAS_CONFIGURE= yes
1.79 jlam 24: CONFIGURE_SCRIPT= ./config
1.202 adam 25: CONFIGURE_ARGS+= --prefix=${PREFIX}
1.131 tnn 26: CONFIGURE_ARGS+= --install_prefix=${DESTDIR}
1.202 adam 27: CONFIGURE_ARGS+= --openssldir=${PKG_SYSCONFDIR}
1.158 jnemeth 28: CONFIGURE_ARGS+= shared no-fips
1.98 jlam 29:
1.224 jperkin 30: .include "../../mk/compiler.mk"
31:
1.217 jperkin 32: # Avoid dependency on 'makedepend' on platforms where the default CC is set
33: # to 'cc' not 'gcc' in boostrap-mk-files. OpenSSL only supports the latter.
1.218 jperkin 34: .if ${PKGSRC_COMPILER} == "gcc" && ${CC} == "cc"
35: CC= gcc
1.217 jperkin 36: .endif
37:
1.114 grant 38: .if ${OPSYS} == "SunOS"
39: . if ${MACHINE_ARCH} == "sparc"
1.219 jperkin 40: OPENSSL_MACHINE_ARCH= sparcv7
41: . elif ${MACHINE_ARCH} == "sparc64"
42: OPENSSL_MACHINE_ARCH= sparcv9
1.114 grant 43: . elif ${MACHINE_ARCH} == "i386"
44: OPENSSL_MACHINE_ARCH= x86
45: . elif ${MACHINE_ARCH} == "x86_64"
46: OPENSSL_MACHINE_ARCH= ${MACHINE_ARCH}
47: . endif
48: # only override the configure target if we know the platform, falling
49: # back to ./config's autodetection if not.
50: . if defined(OPENSSL_MACHINE_ARCH) && !empty(OPENSSL_MACHINE_ARCH)
1.79 jlam 51: CONFIGURE_SCRIPT= ./Configure
1.215 jperkin 52: . if ${PKGSRC_COMPILER} == "clang" || ${PKGSRC_COMPILER} == "gcc"
1.155 tez 53: CONFIGURE_ARGS+= solaris${${ABI}==64:?64:}-${OPENSSL_MACHINE_ARCH}-gcc
1.114 grant 54: . else
1.155 tez 55: CONFIGURE_ARGS+= solaris${${ABI}==64:?64:}-${OPENSSL_MACHINE_ARCH}-cc
1.114 grant 56: . endif
1.79 jlam 57: . endif
58: .elif ${OPSYS} == "IRIX"
59: CONFIGURE_ARGS+= no-asm
1.205 tnn 60: . if defined(ABI) && ${ABI} == "64"
1.79 jlam 61: CONFIGURE_SCRIPT= ./Configure
1.118 cbiere 62: . if !empty(CC_VERSION:Mgcc*)
63: CONFIGURE_ARGS+= irix64-mips4-gcc
64: . else
1.79 jlam 65: CONFIGURE_ARGS+= irix64-mips4-cc
1.118 cbiere 66: . endif
1.79 jlam 67: . endif
1.127 tnn 68: .elif ${OPSYS} == "OSF1"
1.180 joerg 69: USE_PLIST_SHLIB= no
1.127 tnn 70: CONFIGURE_SCRIPT= ./Configure
71: . if !empty(CC_VERSION:Mgcc*)
1.131 tnn 72: CONFIGURE_ARGS+= tru64-alpha-gcc
1.127 tnn 73: . else
1.131 tnn 74: CONFIGURE_ARGS+= tru64-alpha-cc
1.127 tnn 75: . endif
1.123 tron 76: .elif ${OPSYS} == "Darwin"
1.148 adam 77: CONFIGURE_SCRIPT= ./Configure
1.150 obache 78: . if defined(ABI) && ${ABI} == "64"
1.231 bsiegert 79: _OS= darwin64
1.148 adam 80: . else
1.231 bsiegert 81: _OS= darwin
1.148 adam 82: . endif
1.231 bsiegert 83: . if ${MACHINE_ARCH:Mpowerpc*}
84: _ARCH= ppc
85: . else
86: _ARCH= ${MACHINE_ARCH}
87: .endif
88: CONFIGURE_ARGS+= ${_OS}-${_ARCH}-cc
1.148 adam 89:
1.123 tron 90: SUBST_CLASSES+= dl
1.125 tron 91: SUBST_MESSAGE.dl= Adding dynamic link compatibility library.
1.123 tron 92: SUBST_STAGE.dl= post-configure
93: SUBST_FILES.dl= Makefile apps/Makefile crypto/Makefile \
1.131 tnn 94: crypto/pkcs7/Makefile test/Makefile
95: SUBST_SED.dl= -e 's,^EX_LIBS=,EX_LIBS=${DL_LDFLAGS:Q} ,g'
1.141 obache 96:
1.196 wiz 97: .elif ${OPSYS} == "AIX"
1.202 adam 98: CONFIGURE_SCRIPT= ./Configure
99: . if defined(ABI) && ${ABI} == "64"
100: . if !empty(CC_VERSION:Mgcc*)
101: CONFIGURE_ARGS+= aix64-gcc
102: . else
103: CONFIGURE_ARGS+= aix64-cc
104: . endif
105: . else
106: . if !empty(CC_VERSION:Mgcc*)
107: CONFIGURE_ARGS+= aix-gcc
108: . else
109: CONFIGURE_ARGS+= aix-cc
110: . endif
111: . endif
1.141 obache 112: .elif ${OPSYS} == "Interix"
113: SUBST_CLASSES+= soname
114: SUBST_STAGE.soname= post-configure
115: SUBST_FILES.soname= Makefile.shared
116: SUBST_SED.soname= -e 's/-Wl,-soname=/-Wl,-h,/g'
1.161 sno 117: .elif ${OPSYS} == "HPUX"
118: CONFIGURE_SCRIPT= ./Configure
1.205 tnn 119: . if defined(ABI) && ${ABI} == "64"
1.206 tnn 120: . if ${MACHINE_ARCH} == "hppa64"
1.161 sno 121: CONFIGURE_ARGS+= hpux64-parisc2-${CC}
122: . else
123: CONFIGURE_ARGS+= hpux64-ia64-${CC}
124: . endif
125: . else
126: . if ${MACHINE_ARCH} == "hppa"
127: CONFIGURE_ARGS+= hpux-parisc-${CC}
128: . else
129: CONFIGURE_ARGS+= hpux-ia64-${CC}
130: . endif
131: . endif
1.182 joerg 132: .elif ${OPSYS} == "Linux"
133: . if ${MACHINE_ARCH} == "powerpc64"
134: CONFIGURE_SCRIPT= ./Configure
135: CONFIGURE_ARGS+= linux-ppc64
1.214 jperkin 136: . elif ${MACHINE_ARCH} == "i386"
137: CONFIGURE_SCRIPT= ./Configure
138: CONFIGURE_ARGS+= linux-elf
1.182 joerg 139: . endif
1.194 ryoon 140: .elif ${OS_VARIANT} == "SCOOSR5"
141: # SIGILL in _sha1_block_data_order_ssse3().
142: CONFIGURE_ARGS+= no-sse2
1.79 jlam 143: .endif
144:
1.102 jlam 145: .include "../../security/openssl/options.mk"
146:
1.79 jlam 147: CONFIGURE_ARGS+= ${CFLAGS} ${LDFLAGS}
1.109 rillig 148: CONFIGURE_ENV+= PERL=${PERL5:Q}
1.14 veego 149:
1.192 obache 150: PKGCONFIG_OVERRIDE+= libcrypto.pc libssl.pc openssl.pc
151: PKGCONFIG_OVERRIDE_STAGE= post-build
152:
1.181 jperkin 153: PLIST_SRC+= ${PKGDIR}/PLIST.common
1.180 joerg 154: USE_PLIST_SHLIB?= yes
155: .if ${USE_PLIST_SHLIB} == "yes"
156: PLIST_SRC+= ${PKGDIR}/PLIST.shlib
1.92 jlam 157: .endif
1.101 jlam 158: PLIST_SUBST+= SHLIB_VERSION=${OPENSSL_VERS:C/[^0-9]*$//}
159: PLIST_SUBST+= SHLIB_MAJOR=${OPENSSL_VERS:C/\..*$//}
1.98 jlam 160:
1.54 jlam 161: PKG_SYSCONFSUBDIR= openssl
1.53 fredb 162: CONF_FILES= ${PREFIX}/share/examples/openssl/openssl.cnf \
163: ${PKG_SYSCONFDIR}/openssl.cnf
1.54 jlam 164: OWN_DIRS= ${PKG_SYSCONFDIR}/certs ${PKG_SYSCONFDIR}/private
1.76 jschauma 165:
1.144 taca 166: INSTALLATION_DIRS+= share/examples/openssl
167:
1.131 tnn 168: # Fix the path to perl in various scripts.
1.79 jlam 169: pre-configure:
170: cd ${WRKSRC} && ${PERL5} util/perlpath.pl ${PERL5}
1.42 tron 171:
1.235 jperkin 172: # BN_print.3 and bn_print.3 cannot co-exist on Darwin, we choose to remove
173: # bn_print.3 simply because it has more aliases to the same manual page.
174: PLIST_VARS+= notmac
175: .if ${OPSYS} == "Darwin"
176: post-install:
1.236 tron 177: ${CP} -p ${DESTDIR}${PREFIX}/${PKGMANDIR}/man3/BN_print.3 ${WRKDIR}
1.235 jperkin 178: ${RM} ${DESTDIR}${PREFIX}/${PKGMANDIR}/man3/bn_print.3*
1.236 tron 179: ${MV} -f ${WRKDIR}/BN_print.3 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man3
1.235 jperkin 180: .else
181: PLIST.notmac= yes
182: .endif
183:
1.203 tnn 184: .include "../../mk/dlopen.buildlink3.mk"
1.121 tron 185: .include "../../mk/bsd.pkg.mk"
CVSweb <webmaster@jp.NetBSD.org>