diff options
author | Ben Laurie <ben@openssl.org> | 2004-03-10 09:23:51 +0000 |
---|---|---|
committer | Ben Laurie <ben@openssl.org> | 2004-03-10 09:23:51 +0000 |
commit | a82d1527c4effe4e240412662fe9ba386d535e68 (patch) | |
tree | 8581fb231c137f1aa1d0877f690f4d2db228b638 | |
parent | 5a8fe267202c943e71b96488f3784a7fcd74d460 (diff) |
Step 1 in blowing away Makefile.ssl
-rw-r--r-- | Makefile | 918 | ||||
-rw-r--r-- | apps/Makefile (renamed from apps/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/Makefile (renamed from crypto/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/aes/Makefile (renamed from crypto/aes/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/asn1/Makefile (renamed from crypto/asn1/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/bf/Makefile (renamed from crypto/bf/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/bio/Makefile (renamed from crypto/bio/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/bn/Makefile (renamed from crypto/bn/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/buffer/Makefile (renamed from crypto/buffer/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/cast/Makefile (renamed from crypto/cast/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/comp/Makefile (renamed from crypto/comp/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/conf/Makefile (renamed from crypto/conf/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/des/Makefile (renamed from crypto/des/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/dh/Makefile (renamed from crypto/dh/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/dsa/Makefile (renamed from crypto/dsa/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/dso/Makefile (renamed from crypto/dso/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/ec/Makefile (renamed from crypto/ec/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/engine/Makefile (renamed from crypto/engine/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/err/Makefile (renamed from crypto/err/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/evp/Makefile (renamed from crypto/evp/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/hmac/Makefile (renamed from crypto/hmac/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/idea/Makefile (renamed from crypto/idea/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/krb5/Makefile (renamed from crypto/krb5/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/lhash/Makefile (renamed from crypto/lhash/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/md2/Makefile (renamed from crypto/md2/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/md4/Makefile (renamed from crypto/md4/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/md5/Makefile (renamed from crypto/md5/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/mdc2/Makefile (renamed from crypto/mdc2/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/objects/Makefile (renamed from crypto/objects/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/ocsp/Makefile (renamed from crypto/ocsp/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/pem/Makefile (renamed from crypto/pem/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/pkcs12/Makefile (renamed from crypto/pkcs12/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/pkcs7/Makefile (renamed from crypto/pkcs7/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/rand/Makefile (renamed from crypto/rand/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/rc2/Makefile (renamed from crypto/rc2/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/rc4/Makefile (renamed from crypto/rc4/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/rc5/Makefile (renamed from crypto/rc5/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/ripemd/Makefile (renamed from crypto/ripemd/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/rsa/Makefile (renamed from crypto/rsa/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/sha/Makefile (renamed from crypto/sha/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/stack/Makefile (renamed from crypto/stack/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/txt_db/Makefile (renamed from crypto/txt_db/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/ui/Makefile (renamed from crypto/ui/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/x509/Makefile (renamed from crypto/x509/Makefile.ssl) | 0 | ||||
-rw-r--r-- | crypto/x509v3/Makefile (renamed from crypto/x509v3/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/Makefile (renamed from fips/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/aes/Makefile (renamed from fips/aes/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/des/Makefile (renamed from fips/des/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/dsa/Makefile (renamed from fips/dsa/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/rand/Makefile (renamed from fips/rand/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/rsa/Makefile (renamed from fips/rsa/Makefile.ssl) | 0 | ||||
-rw-r--r-- | fips/sha1/Makefile (renamed from fips/sha1/Makefile.ssl) | 0 | ||||
-rw-r--r-- | ssl/Makefile (renamed from ssl/Makefile.ssl) | 0 | ||||
-rw-r--r-- | test/Makefile (renamed from test/Makefile.ssl) | 0 | ||||
-rw-r--r-- | tools/Makefile (renamed from tools/Makefile.ssl) | 0 |
55 files changed, 918 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000000..47cc4183b6 --- /dev/null +++ b/Makefile @@ -0,0 +1,918 @@ +### Generated automatically from Makefile.org by Configure. + +## +## Makefile for OpenSSL +## + +VERSION=0.9.7d-dev +MAJOR=0 +MINOR=9.7 +SHLIB_VERSION_NUMBER=0.9.7 +SHLIB_VERSION_HISTORY= +SHLIB_MAJOR=0 +SHLIB_MINOR=9.7 +SHLIB_EXT=.so.$(SHLIB_MAJOR).$(SHLIB_MINOR) +PLATFORM=FreeBSD-elf +OPTIONS=fips --prefix=/tmp/ssl 386 no-krb5 +CONFIGURE_ARGS=FreeBSD-elf fips --prefix=/tmp/ssl 386 +SHLIB_TARGET=bsd-gcc-shared + +# HERE indicates where this Makefile lives. This can be used to indicate +# where sub-Makefiles are expected to be. Currently has very limited usage, +# and should probably not be bothered with at all. +HERE=. + +# INSTALL_PREFIX is for package builders so that they can configure +# for, say, /usr/ and yet have everything installed to /tmp/somedir/usr/. +# Normally it is left empty. +INSTALL_PREFIX= +INSTALLTOP=/tmp/ssl + +# Do not edit this manually. Use Configure --openssldir=DIR do change this! +OPENSSLDIR=/tmp/ssl/ssl + +# NO_IDEA - Define to build without the IDEA algorithm +# NO_RC4 - Define to build without the RC4 algorithm +# NO_RC2 - Define to build without the RC2 algorithm +# THREADS - Define when building with threads, you will probably also need any +# system defines as well, i.e. _REENTERANT for Solaris 2.[34] +# TERMIO - Define the termio terminal subsystem, needed if sgtty is missing. +# TERMIOS - Define the termios terminal subsystem, Silicon Graphics. +# LONGCRYPT - Define to use HPUX 10.x's long password modification to crypt(3). +# DEVRANDOM - Give this the value of the 'random device' if your OS supports +# one. 32 bytes will be read from this when the random +# number generator is initalised. +# SSL_FORBID_ENULL - define if you want the server to be not able to use the +# NULL encryption ciphers. +# +# LOCK_DEBUG - turns on lots of lock debug output :-) +# REF_CHECK - turn on some xyz_free() assertions. +# REF_PRINT - prints some stuff on structure free. +# CRYPTO_MDEBUG - turns on my 'memory leak' detecting stuff +# MFUNC - Make all Malloc/Free/Realloc calls call +# CRYPTO_malloc/CRYPTO_free/CRYPTO_realloc which can be setup to +# call application defined callbacks via CRYPTO_set_mem_functions() +# MD5_ASM needs to be defined to use the x86 assembler for MD5 +# SHA1_ASM needs to be defined to use the x86 assembler for SHA1 +# RMD160_ASM needs to be defined to use the x86 assembler for RIPEMD160 +# Do not define B_ENDIAN or L_ENDIAN if 'unsigned long' == 8. It must +# equal 4. +# PKCS1_CHECK - pkcs1 tests. + +CC= gcc +#CFLAG= -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall -Wuninitialized -DSHA1_ASM -DMD5_ASM -DRMD160_ASM +CFLAG= -DOPENSSL_THREADS -pthread -D_REENTRANT -D_THREAD_SAFE -D_THREADSAFE -DDSO_DLFCN -DHAVE_DLFCN_H -DOPENSSL_NO_KRB5 -DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall -DMD5_ASM -DRMD160_ASM +DEPFLAG= +PEX_LIBS= +EX_LIBS= +EXE_EXT= +ARFLAGS= +AR=ar $(ARFLAGS) r +RANLIB= /usr/bin/ranlib +PERL= /usr/bin/perl5 +TAR= tar +TARFLAGS= --no-recursion +MAKEDEPPROG= gcc + +# We let the C compiler driver to take care of .s files. This is done in +# order to be excused from maintaining a separate set of architecture +# dependent assembler flags. E.g. if you throw -mcpu=ultrasparc at SPARC +# gcc, then the driver will automatically translate it to -xarch=v8plus +# and pass it down to assembler. +AS=$(CC) -c +ASFLAG=$(CFLAG) + +# Set BN_ASM to bn_asm.o if you want to use the C version +BN_ASM= asm/bn86-elf.o asm/co86-elf.o +#BN_ASM= bn_asm.o +#BN_ASM= asm/bn86-elf.o # elf, linux-elf +#BN_ASM= asm/bn86-sol.o # solaris +#BN_ASM= asm/bn86-out.o # a.out, FreeBSD +#BN_ASM= asm/bn86bsdi.o # bsdi +#BN_ASM= asm/alpha.o # DEC Alpha +#BN_ASM= asm/pa-risc2.o # HP-UX PA-RISC +#BN_ASM= asm/r3000.o # SGI MIPS cpu +#BN_ASM= asm/sparc.o # Sun solaris/SunOS +#BN_ASM= asm/bn-win32.o # Windows 95/NT +#BN_ASM= asm/x86w16.o # 16 bit code for Windows 3.1/DOS +#BN_ASM= asm/x86w32.o # 32 bit code for Windows 3.1 + +# For x86 assembler: Set PROCESSOR to 386 if you want to support +# the 80386. +PROCESSOR= 386 + +# Set DES_ENC to des_enc.o if you want to use the C version +#There are 4 x86 assember options. +DES_ENC= des_enc.o fcrypt_b.o +#DES_ENC= des_enc.o fcrypt_b.o # C +#DES_ENC= asm/dx86-elf.o asm/yx86-elf.o # elf +#DES_ENC= asm/dx86-sol.o asm/yx86-sol.o # solaris +#DES_ENC= asm/dx86-out.o asm/yx86-out.o # a.out, FreeBSD +#DES_ENC= asm/dx86bsdi.o asm/yx86bsdi.o # bsdi + +# Set BF_ENC to bf_enc.o if you want to use the C version +#There are 4 x86 assember options. +BF_ENC= asm/bx86-elf.o +#BF_ENC= bf_enc.o +#BF_ENC= asm/bx86-elf.o # elf +#BF_ENC= asm/bx86-sol.o # solaris +#BF_ENC= asm/bx86-out.o # a.out, FreeBSD +#BF_ENC= asm/bx86bsdi.o # bsdi + +# Set CAST_ENC to c_enc.o if you want to use the C version +#There are 4 x86 assember options. +CAST_ENC= asm/cx86-elf.o +#CAST_ENC= c_enc.o +#CAST_ENC= asm/cx86-elf.o # elf +#CAST_ENC= asm/cx86-sol.o # solaris +#CAST_ENC= asm/cx86-out.o # a.out, FreeBSD +#CAST_ENC= asm/cx86bsdi.o # bsdi + +# Set RC4_ENC to rc4_enc.o if you want to use the C version +#There are 4 x86 assember options. +RC4_ENC= asm/rx86-elf.o +#RC4_ENC= rc4_enc.o +#RC4_ENC= asm/rx86-elf.o # elf +#RC4_ENC= asm/rx86-sol.o # solaris +#RC4_ENC= asm/rx86-out.o # a.out, FreeBSD +#RC4_ENC= asm/rx86bsdi.o # bsdi + +# Set RC5_ENC to rc5_enc.o if you want to use the C version +#There are 4 x86 assember options. +RC5_ENC= asm/r586-elf.o +#RC5_ENC= rc5_enc.o +#RC5_ENC= asm/r586-elf.o # elf +#RC5_ENC= asm/r586-sol.o # solaris +#RC5_ENC= asm/r586-out.o # a.out, FreeBSD +#RC5_ENC= asm/r586bsdi.o # bsdi + +# Also need MD5_ASM defined +MD5_ASM_OBJ= asm/mx86-elf.o +#MD5_ASM_OBJ= asm/mx86-elf.o # elf +#MD5_ASM_OBJ= asm/mx86-sol.o # solaris +#MD5_ASM_OBJ= asm/mx86-out.o # a.out, FreeBSD +#MD5_ASM_OBJ= asm/mx86bsdi.o # bsdi + +# Also need SHA1_ASM defined +SHA1_ASM_OBJ= +#SHA1_ASM_OBJ= asm/sx86-elf.o # elf +#SHA1_ASM_OBJ= asm/sx86-sol.o # solaris +#SHA1_ASM_OBJ= asm/sx86-out.o # a.out, FreeBSD +#SHA1_ASM_OBJ= asm/sx86bsdi.o # bsdi + +# Also need RMD160_ASM defined +RMD160_ASM_OBJ= asm/rm86-elf.o +#RMD160_ASM_OBJ= asm/rm86-elf.o # elf +#RMD160_ASM_OBJ= asm/rm86-sol.o # solaris +#RMD160_ASM_OBJ= asm/rm86-out.o # a.out, FreeBSD +#RMD160_ASM_OBJ= asm/rm86bsdi.o # bsdi + +# KRB5 stuff +KRB5_INCLUDES= +LIBKRB5= + +# When we're prepared to use shared libraries in the programs we link here +# we might set SHLIB_MARK to '$(SHARED_LIBS)'. +SHLIB_MARK= + +DIRS= crypto fips ssl $(SHLIB_MARK) sigs apps test tools +SHLIBDIRS= fips crypto ssl + +# dirs in crypto to build +SDIRS= objects \ + md2 md4 md5 sha mdc2 hmac ripemd \ + des rc2 rc4 rc5 idea bf cast \ + bn ec rsa dsa dh dso engine aes \ + buffer bio stack lhash rand err \ + evp asn1 pem x509 x509v3 conf txt_db pkcs7 pkcs12 comp ocsp ui krb5 + +FDIRS= sha1 rand des aes dsa rsa + +# tests to perform. "alltests" is a special word indicating that all tests +# should be performed. +TESTS = alltests + +MAKEFILE= Makefile.ssl +MAKE= make -f Makefile.ssl + +MANDIR=$(OPENSSLDIR)/man +MAN1=1 +MAN3=3 +MANSUFFIX= +SHELL=/bin/sh + +TOP= . +ONEDIRS=out tmp +EDIRS= times doc bugs util include certs ms shlib mt demos perl sf dep VMS +WDIRS= windows +LIBS= libcrypto.a libssl.a +SIGS= libcrypto.sha1 +SHARED_CRYPTO=libcrypto$(SHLIB_EXT) +SHARED_SSL=libssl$(SHLIB_EXT) +SHARED_LIBS= +SHARED_LIBS_LINK_EXTS=.so.$(SHLIB_MAJOR) .so +SHARED_LDFLAGS= + +GENERAL= Makefile +BASENAME= openssl +NAME= $(BASENAME)-$(VERSION) +TARFILE= $(NAME).tar +WTARFILE= $(NAME)-win.tar +EXHEADER= e_os2.h +HEADER= e_os.h + +# When we're prepared to use shared libraries in the programs we link here +# we might remove 'clean-shared' from the targets to perform at this stage + +all: Makefile.ssl sub_all openssl.pc + +sigs: $(SIGS) +libcrypto.sha1: libcrypto.a + if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \ + $(RANLIB) libcrypto.a; \ + fips/sha1/fips_standalone_sha1 libcrypto.a > libcrypto.sha1; \ + fi + +sub_all: + @for i in $(DIRS); \ + do \ + if [ -d "$$i" ]; then \ + (cd $$i && echo "making all in $$i..." && \ + $(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' AS='${AS}' ASFLAG='${ASFLAG}' SDIRS='$(SDIRS)' FDIRS='$(FDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' all ) || exit 1; \ + else \ + $(MAKE) $$i; \ + fi; \ + done; + +sub_target: + @for i in $(DIRS); \ + do \ + if [ -d "$$i" ]; then \ + (cd $$i && echo "making $(TARGET) in $$i..." && \ + $(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' AS='${AS}' ASFLAG='${ASFLAG}' SDIRS='$(SDIRS)' FDIRS='$(FDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TARGET='$(TARGET)' sub_target ) || exit 1; \ + else \ + $(MAKE) $$i; \ + fi; \ + done; + +libcrypto$(SHLIB_EXT): libcrypto.a + @if [ "$(SHLIB_TARGET)" != "" ]; then \ + $(MAKE) SHLIBDIRS=crypto build-shared; \ + else \ + echo "There's no support for shared libraries on this platform" >&2; \ + fi + +libssl$(SHLIB_EXT): libcrypto$(SHLIB_EXT) libssl.a + @if [ "$(SHLIB_TARGET)" != "" ]; then \ + $(MAKE) SHLIBDIRS=ssl SHLIBDEPS='-lcrypto' build-shared; \ + else \ + echo "There's no support for shared libraries on this platform" >&2; \ + fi + +clean-shared: + @for i in $(SHLIBDIRS); do \ + if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \ + tmp="$(SHARED_LIBS_LINK_EXTS)"; \ + for j in $${tmp:-x}; do \ + ( set -x; rm -f lib$$i$$j ); \ + done; \ + fi; \ + ( set -x; rm -f lib$$i$(SHLIB_EXT) ); \ + if [ "$(PLATFORM)" = "Cygwin" ]; then \ + ( set -x; rm -f cyg$$i-$(SHLIB_VERSION_NUMBER)$(SHLIB_EXT) lib$$i$(SHLIB_EXT).a ); \ + fi; \ + done + +link-shared: + @if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \ + tmp="$(SHARED_LIBS_LINK_EXTS)"; \ + for i in $(SHLIBDIRS); do \ + prev=lib$$i$(SHLIB_EXT); \ + for j in $${tmp:-x}; do \ + ( set -x; \ + rm -f lib$$i$$j; ln -s $$prev lib$$i$$j ); \ + prev=lib$$i$$j; \ + done; \ + done; \ + fi + +build-shared: clean-shared do_$(SHLIB_TARGET) link-shared + +do_bsd-gcc-shared: do_gnu-shared +do_linux-shared: do_gnu-shared +do_gnu-shared: + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} ${SHARED_LDFLAGS} \ + -shared -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -Wl,-soname=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -Wl,-Bsymbolic \ + -Wl,--whole-archive lib$$i.a \ + -Wl,--no-whole-archive $$libs ${EX_LIBS} -lc ) || exit 1; \ + libs="-l$$i $$libs"; \ + done + +DETECT_GNU_LD=(${CC} -Wl,-V /dev/null 2>&1 | grep '^GNU ld' )>/dev/null + +# For Darwin AKA Mac OS/X (dyld) +do_darwin-shared: + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} --verbose -dynamiclib -o lib$$i${SHLIB_EXT} \ + lib$$i.a $$libs -all_load -current_version ${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -compatibility_version ${SHLIB_MAJOR}.`echo ${SHLIB_MINOR} | cut -d. -f1` \ + -install_name ${INSTALLTOP}/lib/lib$$i${SHLIB_EXT} ) || exit 1; \ + libs="-l`basename $$i${SHLIB_EXT} .dylib` $$libs"; \ + echo "" ; \ + done + +do_cygwin-shared: + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} -shared -o cyg$$i-$(SHLIB_VERSION_NUMBER).dll \ + -Wl,-Bsymbolic \ + -Wl,--whole-archive lib$$i.a \ + -Wl,--out-implib,lib$$i.dll.a \ + -Wl,--no-whole-archive $$libs ) || exit 1; \ + libs="-l$$i $$libs"; \ + done + +# This assumes that GNU utilities are *not* used +do_alpha-osf1-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} ${SHARED_LDFLAGS} \ + -shared -o lib$$i.so \ + -set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \ + -all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# This assumes that GNU utilities are *not* used +# The difference between alpha-osf1-shared and tru64-shared is the `-msym' +# option passed to the linker. +do_tru64-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} ${SHARED_LDFLAGS} \ + -shared -msym -o lib$$i.so \ + -set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \ + -all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# This assumes that GNU utilities are *not* used +# The difference between tru64-shared and tru64-shared-rpath is the +# -rpath ${INSTALLTOP}/lib passed to the linker. +do_tru64-shared-rpath: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} ${SHARED_LDFLAGS} \ + -shared -msym -o lib$$i.so \ + -rpath ${INSTALLTOP}/lib \ + -set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \ + -all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + + +# This assumes that GNU utilities are *not* used +do_solaris-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( PATH=/usr/ccs/bin:$$PATH ; export PATH; \ + MINUSZ='-z '; \ + (${CC} -v 2>&1 | grep gcc) > /dev/null && MINUSZ='-Wl,-z,'; \ + set -x; ${CC} ${SHARED_LDFLAGS} -G -dy -z text \ + -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + $${MINUSZ}allextract lib$$i.a $${MINUSZ}defaultextract \ + $$libs ${EX_LIBS} -lc ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# OpenServer 5 native compilers used +do_svr3-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( PATH=/usr/ccs/bin:$$PATH ; export PATH; \ + find . -name "*.o" -print > allobjs ; \ + OBJS= ; export OBJS ; \ + for obj in `ar t lib$$i.a` ; do \ + OBJS="$${OBJS} `grep /$$obj allobjs`" ; \ + done ; \ + set -x; ${CC} ${SHARED_LDFLAGS} \ + -G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + $${OBJS} $$libs ${EX_LIBS} ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# UnixWare 7 and OpenUNIX 8 native compilers used +do_svr5-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( PATH=/usr/ccs/bin:$$PATH ; export PATH; \ + SHARE_FLAG='-G'; \ + (${CC} -v 2>&1 | grep gcc) > /dev/null && SHARE_FLAG='-shared'; \ + find . -name "*.o" -print > allobjs ; \ + OBJS= ; export OBJS ; \ + for obj in `ar t lib$$i.a` ; do \ + OBJS="$${OBJS} `grep /$$obj allobjs`" ; \ + done ; \ + set -x; LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH \ + ${CC} ${SHARED_LDFLAGS} \ + $${SHARE_FLAG} -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + $${OBJS} $$libs ${EX_LIBS} ) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# This assumes that GNU utilities are *not* used +do_irix-shared: + if ${DETECT_GNU_LD}; then \ + $(MAKE) do_gnu-shared; \ + else \ + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; ${CC} ${SHARED_LDFLAGS} \ + -shared -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -Wl,-soname,lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -all lib$$i.a $$libs ${EX_LIBS} -lc) || exit 1; \ + libs="-l$$i $$libs"; \ + done; \ + fi + +# This assumes that GNU utilities are *not* used +# HP-UX includes the full pathname of libs we depend on, so we would get +# ./libcrypto (with ./ as path information) compiled into libssl, hence +# we omit the SHLIBDEPS. Applications must be linked with -lssl -lcrypto +# anyway. +# The object modules are loaded from lib$i.a using the undocumented -Fl +# option. +# +# WARNING: Until DSO is fixed to support a search path, we support SHLIB_PATH +# by temporarily specifying "+s"! +# +do_hpux-shared: + for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; /usr/ccs/bin/ld ${SHARED_LDFLAGS} \ + +vnocompatwarnings \ + -b -z +s \ + -o lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + +h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + -Fl lib$$i.a -ldld -lc ) || exit 1; \ + chmod a=rx lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR}; \ + done + +# This assumes that GNU utilities are *not* used +# HP-UX includes the full pathname of libs we depend on, so we would get +# ./libcrypto (with ./ as path information) compiled into libssl, hence +# we omit the SHLIBDEPS. Applications must be linked with -lssl -lcrypto +# anyway. +# +# HP-UX in 64bit mode has "+s" enabled by default; it will search for +# shared libraries along LD_LIBRARY_PATH _and_ SHLIB_PATH. +# +do_hpux64-shared: + for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; /usr/ccs/bin/ld ${SHARED_LDFLAGS} \ + -b -z \ + -o lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + +h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \ + +forceload lib$$i.a -ldl -lc ) || exit 1; \ + chmod a=rx lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR}; \ + done + +# The following method is said to work on all platforms. Tests will +# determine if that's how it's gong to be used. +# This assumes that for all but GNU systems, GNU utilities are *not* used. +# ALLSYMSFLAGS would be: +# GNU systems: --whole-archive +# Tru64 Unix: -all +# Solaris: -z allextract +# Irix: -all +# HP/UX-32bit: -Fl +# HP/UX-64bit: +forceload +# AIX: -bnogc +# SHAREDFLAGS would be: +# GNU systems: -shared -Wl,-soname=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} +# Tru64 Unix: -shared \ +# -set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" +# Solaris: -G -h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} +# Irix: -shared -Wl,-soname,lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} +# HP/UX-32bit: +vnocompatwarnings -b -z +s \ +# +h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} +# HP/UX-64bit: -b -z +h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} +# AIX: -G -bE:lib$$i.exp -bM:SRE +# SHAREDCMD would be: +# GNU systems: $(CC) +# Tru64 Unix: $(CC) +# Solaris: $(CC) +# Irix: $(CC) +# HP/UX-32bit: /usr/ccs/bin/ld +# HP/UX-64bit: /usr/ccs/bin/ld +# AIX: $(CC) +ALLSYMSFLAG=-bnogc +SHAREDFLAGS=${SHARED_LDFLAGS} -G -bE:lib$$i.exp -bM:SRE +SHAREDCMD=$(CC) +do_aix-shared: + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + ( set -x; \ + ld -r -o lib$$i.o $(ALLSYMSFLAG) lib$$i.a && \ + ( nm -Pg lib$$i.o | grep ' [BD] ' | cut -f1 -d' ' > lib$$i.exp; \ + $(SHAREDCMD) $(SHAREDFLAGS) \ + -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} lib$$i.o \ + $$libs ${EX_LIBS} ) ) \ + || exit 1; \ + libs="-l$$i $$libs"; \ + done + +do_reliantunix-shared: + libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \ + if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \ + libs="$(LIBKRB5) $$libs"; \ + fi; \ + tmpdir=/tmp/openssl.$$$$ ; rm -rf $$tmpdir ; \ + ( set -x; \ + ( Opwd=` |