1142425Snectar### Generated automatically from Makefile.org by Configure.
2142425Snectar
3142425Snectar##
4142425Snectar## Makefile for OpenSSL
5142425Snectar##
6142425Snectar
7356290SjkimVERSION=1.0.2u
8238405SjkimMAJOR=1
9290207SjkimMINOR=0.2
10238405SjkimSHLIB_VERSION_NUMBER=1.0.0
11142425SnectarSHLIB_VERSION_HISTORY=
12238405SjkimSHLIB_MAJOR=1
13238405SjkimSHLIB_MINOR=0.0
14340704SjkimSHLIB_EXT=.so.$(SHLIB_MAJOR).$(SHLIB_MINOR)
15340704SjkimPLATFORM=linux-x86_64
16340704SjkimOPTIONS=-Wa,--noexecstack no-ec_nistp_64_gcc_128 no-gmp no-jpake no-krb5 no-libunbound no-md2 no-rc5 no-rfc3779 no-sctp no-shared no-ssl-trace no-ssl2 no-store no-unit-test no-weak-ssl-ciphers no-zlib no-zlib-dynamic static-engine
17340704SjkimCONFIGURE_ARGS=linux-x86_64 -Wa,--noexecstack
18340704SjkimSHLIB_TARGET=linux-shared
19142425Snectar
20142425Snectar# HERE indicates where this Makefile lives.  This can be used to indicate
21142425Snectar# where sub-Makefiles are expected to be.  Currently has very limited usage,
22142425Snectar# and should probably not be bothered with at all.
23142425SnectarHERE=.
24142425Snectar
25142425Snectar# INSTALL_PREFIX is for package builders so that they can configure
26142425Snectar# for, say, /usr/ and yet have everything installed to /tmp/somedir/usr/.
27142425Snectar# Normally it is left empty.
28142425SnectarINSTALL_PREFIX=
29142425SnectarINSTALLTOP=/usr/local/ssl
30142425Snectar
31142425Snectar# Do not edit this manually. Use Configure --openssldir=DIR do change this!
32142425SnectarOPENSSLDIR=/usr/local/ssl
33142425Snectar
34142425Snectar# NO_IDEA - Define to build without the IDEA algorithm
35142425Snectar# NO_RC4  - Define to build without the RC4 algorithm
36142425Snectar# NO_RC2  - Define to build without the RC2 algorithm
37142425Snectar# THREADS - Define when building with threads, you will probably also need any
38142425Snectar#           system defines as well, i.e. _REENTERANT for Solaris 2.[34]
39142425Snectar# TERMIO  - Define the termio terminal subsystem, needed if sgtty is missing.
40142425Snectar# TERMIOS - Define the termios terminal subsystem, Silicon Graphics.
41142425Snectar# LONGCRYPT - Define to use HPUX 10.x's long password modification to crypt(3).
42142425Snectar# DEVRANDOM - Give this the value of the 'random device' if your OS supports
43142425Snectar#           one.  32 bytes will be read from this when the random
44142425Snectar#           number generator is initalised.
45142425Snectar# SSL_FORBID_ENULL - define if you want the server to be not able to use the
46142425Snectar#           NULL encryption ciphers.
47142425Snectar#
48142425Snectar# LOCK_DEBUG - turns on lots of lock debug output :-)
49142425Snectar# REF_CHECK - turn on some xyz_free() assertions.
50142425Snectar# REF_PRINT - prints some stuff on structure free.
51142425Snectar# CRYPTO_MDEBUG - turns on my 'memory leak' detecting stuff
52142425Snectar# MFUNC - Make all Malloc/Free/Realloc calls call
53142425Snectar#       CRYPTO_malloc/CRYPTO_free/CRYPTO_realloc which can be setup to
54142425Snectar#       call application defined callbacks via CRYPTO_set_mem_functions()
55142425Snectar# MD5_ASM needs to be defined to use the x86 assembler for MD5
56142425Snectar# SHA1_ASM needs to be defined to use the x86 assembler for SHA1
57142425Snectar# RMD160_ASM needs to be defined to use the x86 assembler for RIPEMD160
58142425Snectar# Do not define B_ENDIAN or L_ENDIAN if 'unsigned long' == 8.  It must
59142425Snectar# equal 4.
60142425Snectar# PKCS1_CHECK - pkcs1 tests.
61142425Snectar
62340704SjkimCC= gcc
63340704SjkimCFLAG= -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -Wa,--noexecstack -m64 -DL_ENDIAN -O3 -Wall -DOPENSSL_IA32_SSE2 -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_MONT5 -DOPENSSL_BN_ASM_GF2m -DRC4_ASM -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DMD5_ASM -DAES_ASM -DVPAES_ASM -DBSAES_ASM -DWHIRLPOOL_ASM -DGHASH_ASM -DECP_NISTZ256_ASM
64296279SjkimDEPFLAG= -DOPENSSL_NO_EC_NISTP_64_GCC_128 -DOPENSSL_NO_GMP -DOPENSSL_NO_JPAKE -DOPENSSL_NO_LIBUNBOUND -DOPENSSL_NO_MD2 -DOPENSSL_NO_RC5 -DOPENSSL_NO_RFC3779 -DOPENSSL_NO_SCTP -DOPENSSL_NO_SSL_TRACE -DOPENSSL_NO_SSL2 -DOPENSSL_NO_STORE -DOPENSSL_NO_UNIT_TEST -DOPENSSL_NO_WEAK_SSL_CIPHERS
65142425SnectarPEX_LIBS= 
66340704SjkimEX_LIBS= -ldl
67142425SnectarEXE_EXT= 
68142425SnectarARFLAGS= 
69205128SsimonAR= ar $(ARFLAGS) r
70142425SnectarRANLIB= /usr/bin/ranlib
71306195SjkimRC= windres
72238405SjkimNM= nm
73352193SjkimPERL= /usr/bin/perl
74142425SnectarTAR= tar
75290207SjkimTARFLAGS= --no-recursion
76340704SjkimMAKEDEPPROG= gcc
77205128SsimonLIBDIR=lib
78142425Snectar
79142425Snectar# We let the C compiler driver to take care of .s files. This is done in
80142425Snectar# order to be excused from maintaining a separate set of architecture
81142425Snectar# dependent assembler flags. E.g. if you throw -mcpu=ultrasparc at SPARC
82142425Snectar# gcc, then the driver will automatically translate it to -xarch=v8plus
83142425Snectar# and pass it down to assembler.
84142425SnectarAS=$(CC) -c
85142425SnectarASFLAG=$(CFLAG)
86142425Snectar
87142425Snectar# For x86 assembler: Set PROCESSOR to 386 if you want to support
88142425Snectar# the 80386.
89142425SnectarPROCESSOR= 
90142425Snectar
91160814Ssimon# CPUID module collects small commonly used assembler snippets
92340704SjkimCPUID_OBJ= x86_64cpuid.o
93340704SjkimBN_ASM= x86_64-gcc.o x86_64-mont.o x86_64-mont5.o x86_64-gf2m.o rsaz_exp.o rsaz-x86_64.o rsaz-avx2.o
94340704SjkimEC_ASM= ecp_nistz256.o ecp_nistz256-x86_64.o
95142425SnectarDES_ENC= des_enc.o fcrypt_b.o
96340704SjkimAES_ENC= aes-x86_64.o vpaes-x86_64.o bsaes-x86_64.o aesni-x86_64.o aesni-sha1-x86_64.o aesni-sha256-x86_64.o aesni-mb-x86_64.o
97142425SnectarBF_ENC= bf_enc.o
98142425SnectarCAST_ENC= c_enc.o
99340704SjkimRC4_ENC= rc4-x86_64.o rc4-md5-x86_64.o
100142425SnectarRC5_ENC= rc5_enc.o
101340704SjkimMD5_ASM_OBJ= md5-x86_64.o
102340704SjkimSHA1_ASM_OBJ= sha1-x86_64.o sha256-x86_64.o sha512-x86_64.o sha1-mb-x86_64.o sha256-mb-x86_64.o
103142425SnectarRMD160_ASM_OBJ= 
104340704SjkimWP_ASM_OBJ= wp-x86_64.o
105340704SjkimCMLL_ENC= cmll-x86_64.o cmll_misc.o
106340704SjkimMODES_ASM_OBJ= ghash-x86_64.o aesni-gcm-x86_64.o
107238405SjkimENGINES_ASM_OBJ= 
108340704SjkimPERLASM_SCHEME= elf
109142425Snectar
110142425Snectar# KRB5 stuff
111142425SnectarKRB5_INCLUDES=
112142425SnectarLIBKRB5=
113142425Snectar
114160814Ssimon# Zlib stuff
115160814SsimonZLIB_INCLUDE=
116160814SsimonLIBZLIB=
117142425Snectar
118238405Sjkim# TOP level FIPS install directory.
119238405SjkimFIPSDIR=/usr/local/ssl/fips-2.0
120238405Sjkim
121194206Ssimon# This is the location of fipscanister.o and friends.
122194206Ssimon# The FIPS module build will place it $(INSTALLTOP)/lib
123194206Ssimon# but since $(INSTALLTOP) can only take the default value
124194206Ssimon# when the module is built it will be in /usr/local/ssl/lib
125238405Sjkim# $(INSTALLTOP) for this build may be different so hard
126194206Ssimon# code the path.
127194206Ssimon
128238405SjkimFIPSLIBDIR=
129194206Ssimon
130194206Ssimon# The location of the library which contains fipscanister.o
131194206Ssimon# normally it will be libcrypto unless fipsdso is set in which
132194206Ssimon# case it will be libfips. If not compiling in FIPS mode at all
133194206Ssimon# this is empty making it a useful test for a FIPS compile.
134194206Ssimon
135194206SsimonFIPSCANLIB=
136194206Ssimon
137194206Ssimon# Shared library base address. Currently only used on Windows.
138194206Ssimon#
139194206Ssimon
140194206SsimonBASEADDR=0xFB00000
141194206Ssimon
142160814SsimonDIRS=   crypto ssl engines apps test tools
143238405SjkimENGDIRS= ccgost
144160814SsimonSHLIBDIRS= crypto ssl
145142425Snectar
146142425Snectar# dirs in crypto to build
147160814SsimonSDIRS=  \
148160814Ssimon	objects \
149238405Sjkim	md4 md5 sha mdc2 hmac ripemd whrlpool \
150238405Sjkim	des aes rc2 rc4 idea bf cast camellia seed modes \
151160814Ssimon	bn ec rsa dsa ecdsa dh ecdh dso engine \
152142425Snectar	buffer bio stack lhash rand err \
153160814Ssimon	evp asn1 pem x509 x509v3 conf txt_db pkcs7 pkcs12 comp ocsp ui krb5 \
154238405Sjkim	cms pqueue ts srp cmac
155160814Ssimon# keep in mind that the above list is adjusted by ./Configure
156160814Ssimon# according to no-xxx arguments...
157142425Snectar
158142425Snectar# tests to perform.  "alltests" is a special word indicating that all tests
159142425Snectar# should be performed.
160142425SnectarTESTS = alltests
161142425Snectar
162142425SnectarMAKEFILE= Makefile
163142425Snectar
164142425SnectarMANDIR=$(OPENSSLDIR)/man
165142425SnectarMAN1=1
166142425SnectarMAN3=3
167142425SnectarMANSUFFIX=
168238405SjkimHTMLSUFFIX=html
169238405SjkimHTMLDIR=$(OPENSSLDIR)/html
170142425SnectarSHELL=/bin/sh
171142425Snectar
172142425SnectarTOP=    .
173142425SnectarONEDIRS=out tmp
174142425SnectarEDIRS=  times doc bugs util include certs ms shlib mt demos perl sf dep VMS
175142425SnectarWDIRS=  windows
176142425SnectarLIBS=   libcrypto.a libssl.a
177142425SnectarSHARED_CRYPTO=libcrypto$(SHLIB_EXT)
178142425SnectarSHARED_SSL=libssl$(SHLIB_EXT)
179142425SnectarSHARED_LIBS=
180340704SjkimSHARED_LIBS_LINK_EXTS=.so.$(SHLIB_MAJOR) .so
181340704SjkimSHARED_LDFLAGS=-m64
182142425Snectar
183142425SnectarGENERAL=        Makefile
184142425SnectarBASENAME=       openssl
185142425SnectarNAME=           $(BASENAME)-$(VERSION)
186295009SjkimTARFILE=        ../$(NAME).tar
187142425SnectarEXHEADER=       e_os2.h
188142425SnectarHEADER=         e_os.h
189142425Snectar
190284283Sjkimall: Makefile build_all
191142425Snectar
192160814Ssimon# as we stick to -e, CLEARENV ensures that local variables in lower
193160814Ssimon# Makefiles remain local and variable. $${VAR+VAR} is tribute to Korn
194160814Ssimon# shell, which [annoyingly enough] terminates unset with error if VAR
195160814Ssimon# is not present:-( TOP= && unset TOP is tribute to HP-UX /bin/sh,
196160814Ssimon# which terminates unset with error if no variable was present:-(
197160814SsimonCLEARENV=	TOP= && unset TOP $${LIB+LIB} $${LIBS+LIBS}	\
198160814Ssimon		$${INCLUDE+INCLUDE} $${INCLUDES+INCLUDES}	\
199160814Ssimon		$${DIR+DIR} $${DIRS+DIRS} $${SRC+SRC}		\
200160814Ssimon		$${LIBSRC+LIBSRC} $${LIBOBJ+LIBOBJ} $${ALL+ALL}	\
201160814Ssimon		$${EXHEADER+EXHEADER} $${HEADER+HEADER}		\
202160814Ssimon		$${GENERAL+GENERAL} $${CFLAGS+CFLAGS}		\
203160814Ssimon		$${ASFLAGS+ASFLAGS} $${AFLAGS+AFLAGS}		\
204238405Sjkim		$${LDCMD+LDCMD} $${LDFLAGS+LDFLAGS} $${SCRIPTS+SCRIPTS}	\
205160814Ssimon		$${SHAREDCMD+SHAREDCMD} $${SHAREDFLAGS+SHAREDFLAGS}	\
206312826Sjkim		$${SHARED_LIB+SHARED_LIB} $${LIBEXTRAS+LIBEXTRAS}	\
207312826Sjkim		$${APPS+APPS}
208142425Snectar
209291719Sjkim# LC_ALL=C ensures that error [and other] messages are delivered in
210291719Sjkim# same language for uniform treatment.
211291719SjkimBUILDENV=	LC_ALL=C PLATFORM='$(PLATFORM)' PROCESSOR='$(PROCESSOR)'\
212238405Sjkim		CC='$(CC)' CFLAG='$(CFLAG)' 			\
213238405Sjkim		AS='$(CC)' ASFLAG='$(CFLAG) -c'			\
214238405Sjkim		AR='$(AR)' NM='$(NM)' RANLIB='$(RANLIB)'	\
215306195Sjkim		RC='$(RC)'              			\
216238405Sjkim		CROSS_COMPILE='$(CROSS_COMPILE)'	\
217238405Sjkim		PERL='$(PERL)' ENGDIRS='$(ENGDIRS)'		\
218238405Sjkim		SDIRS='$(SDIRS)' LIBRPATH='$(INSTALLTOP)/$(LIBDIR)'	\
219238405Sjkim		INSTALL_PREFIX='$(INSTALL_PREFIX)'		\
220238405Sjkim		INSTALLTOP='$(INSTALLTOP)' OPENSSLDIR='$(OPENSSLDIR)'	\
221238405Sjkim		LIBDIR='$(LIBDIR)'				\
222238405Sjkim		MAKEDEPEND='$$$${TOP}/util/domd $$$${TOP} -MD $(MAKEDEPPROG)' \
223238405Sjkim		DEPFLAG='-DOPENSSL_NO_DEPRECATED $(DEPFLAG)'	\
224238405Sjkim		MAKEDEPPROG='$(MAKEDEPPROG)'			\
225238405Sjkim		SHARED_LDFLAGS='$(SHARED_LDFLAGS)'		\
226238405Sjkim		KRB5_INCLUDES='$(KRB5_INCLUDES)' LIBKRB5='$(LIBKRB5)'	\
227238405Sjkim		ZLIB_INCLUDE='$(ZLIB_INCLUDE)' LIBZLIB='$(LIBZLIB)'	\
228238405Sjkim		EXE_EXT='$(EXE_EXT)' SHARED_LIBS='$(SHARED_LIBS)'	\
229238405Sjkim		SHLIB_EXT='$(SHLIB_EXT)' SHLIB_TARGET='$(SHLIB_TARGET)'	\
230238405Sjkim		PEX_LIBS='$(PEX_LIBS)' EX_LIBS='$(EX_LIBS)'	\
231290207Sjkim		CPUID_OBJ='$(CPUID_OBJ)' BN_ASM='$(BN_ASM)'	\
232290207Sjkim		EC_ASM='$(EC_ASM)' DES_ENC='$(DES_ENC)' 	\
233238405Sjkim		AES_ENC='$(AES_ENC)' CMLL_ENC='$(CMLL_ENC)'	\
234238405Sjkim		BF_ENC='$(BF_ENC)' CAST_ENC='$(CAST_ENC)'	\
235238405Sjkim		RC4_ENC='$(RC4_ENC)' RC5_ENC='$(RC5_ENC)'	\
236238405Sjkim		SHA1_ASM_OBJ='$(SHA1_ASM_OBJ)'			\
237238405Sjkim		MD5_ASM_OBJ='$(MD5_ASM_OBJ)'			\
238238405Sjkim		RMD160_ASM_OBJ='$(RMD160_ASM_OBJ)'		\
239238405Sjkim		WP_ASM_OBJ='$(WP_ASM_OBJ)'			\
240238405Sjkim		MODES_ASM_OBJ='$(MODES_ASM_OBJ)'		\
241238405Sjkim		ENGINES_ASM_OBJ='$(ENGINES_ASM_OBJ)'		\
242238405Sjkim		PERLASM_SCHEME='$(PERLASM_SCHEME)'		\
243194206Ssimon		FIPSLIBDIR='${FIPSLIBDIR}'			\
244238405Sjkim		FIPSDIR='${FIPSDIR}'				\
245194206Ssimon		FIPSCANLIB="$${FIPSCANLIB:-$(FIPSCANLIB)}"	\
246160814Ssimon		THIS=$${THIS:-$@} MAKEFILE=Makefile MAKEOVERRIDES=
247160814Ssimon# MAKEOVERRIDES= effectively "equalizes" GNU-ish and SysV-ish make flavors,
248160814Ssimon# which in turn eliminates ambiguities in variable treatment with -e.
249160814Ssimon
250160814Ssimon# BUILD_CMD is a generic macro to build a given target in a given
251160814Ssimon# subdirectory.  The target must be given through the shell variable
252160814Ssimon# `target' and the subdirectory to build in must be given through `dir'.
253160814Ssimon# This macro shouldn't be used directly, use RECURSIVE_BUILD_CMD or
254160814Ssimon# BUILD_ONE_CMD instead.
255160814Ssimon#
256160814Ssimon# BUILD_ONE_CMD is a macro to build a given target in a given
257160814Ssimon# subdirectory if that subdirectory is part of $(DIRS).  It requires
258160814Ssimon# exactly the same shell variables as BUILD_CMD.
259160814Ssimon#
260160814Ssimon# RECURSIVE_BUILD_CMD is a macro to build a given target in all
261160814Ssimon# subdirectories defined in $(DIRS).  It requires that the target
262160814Ssimon# is given through the shell variable `target'.
263160814SsimonBUILD_CMD=  if [ -d "$$dir" ]; then \
264238405Sjkim	    (	cd $$dir && echo "making $$target in $$dir..." && \
265160814Ssimon		$(CLEARENV) && $(MAKE) -e $(BUILDENV) TOP=.. DIR=$$dir $$target \
266160814Ssimon	    ) || exit 1; \
267160814Ssimon	    fi
268160814SsimonRECURSIVE_BUILD_CMD=for dir in $(DIRS); do $(BUILD_CMD); done
269160814SsimonBUILD_ONE_CMD=\
270238405Sjkim	if expr " $(DIRS) " : ".* $$dir " >/dev/null 2>&1; then \
271160814Ssimon		$(BUILD_CMD); \
272142425Snectar	fi
273142425Snectar
274160814Ssimonreflect:
275160814Ssimon	@[ -n "$(THIS)" ] && $(CLEARENV) && $(MAKE) $(THIS) -e $(BUILDENV)
276142425Snectar
277160814Ssimonsub_all: build_all
278285329Sjkim
279160814Ssimonbuild_all: build_libs build_apps build_tests build_tools
280142425Snectar
281284283Sjkimbuild_libs: build_libcrypto build_libssl openssl.pc
282160814Ssimon
283284283Sjkimbuild_libcrypto: build_crypto build_engines libcrypto.pc
284284283Sjkimbuild_libssl: build_ssl libssl.pc
285284283Sjkim
286160814Ssimonbuild_crypto:
287238405Sjkim	@dir=crypto; target=all; $(BUILD_ONE_CMD)
288285329Sjkimbuild_ssl: build_crypto
289160814Ssimon	@dir=ssl; target=all; $(BUILD_ONE_CMD)
290285329Sjkimbuild_engines: build_crypto
291160814Ssimon	@dir=engines; target=all; $(BUILD_ONE_CMD)
292285329Sjkimbuild_apps: build_libs
293160814Ssimon	@dir=apps; target=all; $(BUILD_ONE_CMD)
294285329Sjkimbuild_tests: build_libs
295160814Ssimon	@dir=test; target=all; $(BUILD_ONE_CMD)
296285329Sjkimbuild_tools: build_libs
297160814Ssimon	@dir=tools; target=all; $(BUILD_ONE_CMD)
298160814Ssimon
299160814Ssimonall_testapps: build_libs build_testapps
300160814Ssimonbuild_testapps:
301160814Ssimon	@dir=crypto; target=testapps; $(BUILD_ONE_CMD)
302160814Ssimon
303238405Sjkimfips_premain_dso$(EXE_EXT): libcrypto.a
304238405Sjkim	[ -z "$(FIPSCANLIB)" ] || $(CC) $(CFLAG) -Iinclude \
305238405Sjkim		-DFINGERPRINT_PREMAIN_DSO_LOAD -o $@  \
306238405Sjkim		$(FIPSLIBDIR)fips_premain.c $(FIPSLIBDIR)fipscanister.o \
307238405Sjkim		libcrypto.a $(EX_LIBS)
308238405Sjkim
309238405Sjkimlibcrypto$(SHLIB_EXT): libcrypto.a fips_premain_dso$(EXE_EXT)
310142425Snectar	@if [ "$(SHLIB_TARGET)" != "" ]; then \
311238405Sjkim		if [ "$(FIPSCANLIB)" = "libcrypto" ]; then \
312238405Sjkim			FIPSLD_LIBCRYPTO=libcrypto.a ; \
313238405Sjkim			FIPSLD_CC="$(CC)"; CC=$(FIPSDIR)/bin/fipsld; \
314238405Sjkim			export CC FIPSLD_CC FIPSLD_LIBCRYPTO; \
315238405Sjkim		fi; \
316264278Sjkim		$(MAKE) -e SHLIBDIRS=crypto  CC="$${CC:-$(CC)}" build-shared && \
317264278Sjkim		(touch -c fips_premain_dso$(EXE_EXT) || :); \
318142425Snectar	else \
319142425Snectar		echo "There's no support for shared libraries on this platform" >&2; \
320160814Ssimon		exit 1; \
321142425Snectar	fi
322142425Snectar
323142425Snectarlibssl$(SHLIB_EXT): libcrypto$(SHLIB_EXT) libssl.a
324142425Snectar	@if [ "$(SHLIB_TARGET)" != "" ]; then \
325238405Sjkim		$(MAKE) SHLIBDIRS=ssl SHLIBDEPS='-lcrypto' build-shared; \
326142425Snectar	else \
327142425Snectar		echo "There's no support for shared libraries on this platform" >&2; \
328160814Ssimon		exit 1; \
329142425Snectar	fi
330142425Snectar
331142425Snectarclean-shared:
332160814Ssimon	@set -e; for i in $(SHLIBDIRS); do \
333142425Snectar		if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \
334142425Snectar			tmp="$(SHARED_LIBS_LINK_EXTS)"; \
335142425Snectar			for j in $${tmp:-x}; do \
336142425Snectar				( set -x; rm -f lib$$i$$j ); \
337142425Snectar			done; \
338142425Snectar		fi; \
339142425Snectar		( set -x; rm -f lib$$i$(SHLIB_EXT) ); \
340290207Sjkim		if expr "$(PLATFORM)" : "Cygwin" >/dev/null; then \
341160814Ssimon			( set -x; rm -f cyg$$i$(SHLIB_EXT) lib$$i$(SHLIB_EXT).a ); \
342142425Snectar		fi; \
343142425Snectar	done
344142425Snectar
345142425Snectarlink-shared:
346238405Sjkim	@ set -e; for i in $(SHLIBDIRS); do \
347160814Ssimon		$(MAKE) -f $(HERE)/Makefile.shared -e $(BUILDENV) \
348238405Sjkim			LIBNAME=$$i LIBVERSION=$(SHLIB_MAJOR).$(SHLIB_MINOR) \
349238405Sjkim			LIBCOMPATVERSIONS=";$(SHLIB_VERSION_HISTORY)" \
350160814Ssimon			symlink.$(SHLIB_TARGET); \
351160814Ssimon		libs="$$libs -l$$i"; \
352142425Snectar	done
353142425Snectar
354160814Ssimonbuild-shared: do_$(SHLIB_TARGET) link-shared
355142425Snectar
356160814Ssimondo_$(SHLIB_TARGET):
357238405Sjkim	@ set -e; libs='-L. $(SHLIBDEPS)'; for i in $(SHLIBDIRS); do \
358238405Sjkim		if [ "$$i" = "ssl" -a -n "$(LIBKRB5)" ]; then \
359142425Snectar			libs="$(LIBKRB5) $$libs"; \
360142425Snectar		fi; \
361160814Ssimon		$(CLEARENV) && $(MAKE) -f Makefile.shared -e $(BUILDENV) \
362238405Sjkim			LIBNAME=$$i LIBVERSION=$(SHLIB_MAJOR).$(SHLIB_MINOR) \
363238405Sjkim			LIBCOMPATVERSIONS=";$(SHLIB_VERSION_HISTORY)" \
364160814Ssimon			LIBDEPS="$$libs $(EX_LIBS)" \
365160814Ssimon			link_a.$(SHLIB_TARGET); \
366142425Snectar		libs="-l$$i $$libs"; \
367142425Snectar	done
368142425Snectar
369160814Ssimonlibcrypto.pc: Makefile
370160814Ssimon	@ ( echo 'prefix=$(INSTALLTOP)'; \
371160814Ssimon	    echo 'exec_prefix=$${prefix}'; \
372205128Ssimon	    echo 'libdir=$${exec_prefix}/$(LIBDIR)'; \
373160814Ssimon	    echo 'includedir=$${prefix}/include'; \
374306195Sjkim	    echo 'enginesdir=$${libdir}/engines'; \
375160814Ssimon	    echo ''; \
376160814Ssimon	    echo 'Name: OpenSSL-libcrypto'; \
377160814Ssimon	    echo 'Description: OpenSSL cryptography library'; \
378160814Ssimon	    echo 'Version: '$(VERSION); \
379160814Ssimon	    echo 'Requires: '; \
380238405Sjkim	    echo 'Libs: -L$${libdir} -lcrypto'; \
381238405Sjkim	    echo 'Libs.private: $(EX_LIBS)'; \
382160814Ssimon	    echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libcrypto.pc
383142425Snectar
384160814Ssimonlibssl.pc: Makefile
385160814Ssimon	@ ( echo 'prefix=$(INSTALLTOP)'; \
386160814Ssimon	    echo 'exec_prefix=$${prefix}'; \
387205128Ssimon	    echo 'libdir=$${exec_prefix}/$(LIBDIR)'; \
388160814Ssimon	    echo 'includedir=$${prefix}/include'; \
389160814Ssimon	    echo ''; \
390290207Sjkim	    echo 'Name: OpenSSL-libssl'; \
391160814Ssimon	    echo 'Description: Secure Sockets Layer and cryptography libraries'; \
392160814Ssimon	    echo 'Version: '$(VERSION); \
393290207Sjkim	    echo 'Requires.private: libcrypto'; \
394290207Sjkim	    echo 'Libs: -L$${libdir} -lssl'; \
395238405Sjkim	    echo 'Libs.private: $(EX_LIBS)'; \
396160814Ssimon	    echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libssl.pc
397142425Snectar
398142425Snectaropenssl.pc: Makefile
399142425Snectar	@ ( echo 'prefix=$(INSTALLTOP)'; \
400142425Snectar	    echo 'exec_prefix=$${prefix}'; \
401205128Ssimon	    echo 'libdir=$${exec_prefix}/$(LIBDIR)'; \
402142425Snectar	    echo 'includedir=$${prefix}/include'; \
403142425Snectar	    echo ''; \
404142425Snectar	    echo 'Name: OpenSSL'; \
405142425Snectar	    echo 'Description: Secure Sockets Layer and cryptography libraries and tools'; \
406142425Snectar	    echo 'Version: '$(VERSION); \
407290207Sjkim	    echo 'Requires: libssl libcrypto' ) > openssl.pc
408142425Snectar
409160814SsimonMakefile: Makefile.org Configure config
410160814Ssimon	@echo "Makefile is older than Makefile.org, Configure or config."
411142425Snectar	@echo "Reconfigure the source tree (via './config' or 'perl Configure'), please."
412142425Snectar	@false
413142425Snectar
414142425Snectarlibclean:
415238405Sjkim	rm -f *.map *.so *.so.* *.dylib *.dll engines/*.so engines/*.dll engines/*.dylib *.a engines/*.a */lib */*/lib
416142425Snectar
417142425Snectarclean:	libclean
418142425Snectar	rm -f shlib/*.o *.o core a.out fluff rehash.time testlog make.log cctest cctest.c
419160814Ssimon	@set -e; target=clean; $(RECURSIVE_BUILD_CMD)
420160814Ssimon	rm -f $(LIBS)
421160814Ssimon	rm -f openssl.pc libssl.pc libcrypto.pc
422142425Snectar	rm -f speed.* .pure
423142425Snectar	rm -f $(TARFILE)
424160814Ssimon	@set -e; for i in $(ONEDIRS) ;\
425142425Snectar	do \
426142425Snectar	rm -fr $$i/*; \
427142425Snectar	done
428142425Snectar
429325335Sjkimdistclean: clean
430325335Sjkim	-$(RM) `find . -name .git -prune -o -type l -print`
431325335Sjkim	$(RM) apps/CA.pl
432325335Sjkim	$(RM) test/evptests.txt test/newkey.pem test/testkey.pem test/testreq.pem
433325335Sjkim	$(RM) tools/c_rehash
434325335Sjkim	$(RM) crypto/opensslconf.h
435325335Sjkim	$(RM) Makefile Makefile.bak
436325335Sjkim
437142425Snectarmakefile.one: files
438142425Snectar	$(PERL) util/mk1mf.pl >makefile.one; \
439142425Snectar	sh util/do_ms.sh
440142425Snectar
441142425Snectarfiles:
442142425Snectar	$(PERL) $(TOP)/util/files.pl Makefile > $(TOP)/MINFO
443160814Ssimon	@set -e; target=files; $(RECURSIVE_BUILD_CMD)
444142425Snectar
445142425Snectarlinks:
446142425Snectar	@$(PERL) $(TOP)/util/mkdir-p.pl include/openssl
447142425Snectar	@$(PERL) $(TOP)/util/mklink.pl include/openssl $(EXHEADER)
448160814Ssimon	@set -e; target=links; $(RECURSIVE_BUILD_CMD)
449142425Snectar
450142425Snectargentests:
451142425Snectar	@(cd test && echo "generating dummy tests (if needed)..." && \
452238405Sjkim	$(CLEARENV) && $(MAKE) -e $(BUILDENV) TESTS='$(TESTS)' OPENSSL_DEBUG_MEMORY=on generate );
453142425Snectar
454142425Snectardclean:
455238405Sjkim	rm -rf *.bak include/openssl certs/.0
456160814Ssimon	@set -e; target=dclean; $(RECURSIVE_BUILD_CMD)
457142425Snectar
458142425Snectarrehash: rehash.time
459205128Ssimonrehash.time: certs apps
460205128Ssimon	@if [ -z "$(CROSS_COMPILE)" ]; then \
461205128Ssimon		(OPENSSL="`pwd`/util/opensslwrap.sh"; \
462238405Sjkim		[ -x "apps/openssl.exe" ] && OPENSSL="apps/openssl.exe" || :; \
463205128Ssimon		OPENSSL_DEBUG_MEMORY=on; \
464205128Ssimon		export OPENSSL OPENSSL_DEBUG_MEMORY; \
465246772Sjkim		$(PERL) tools/c_rehash certs/demo) && \
466205128Ssimon		touch rehash.time; \
467238405Sjkim	else :; fi
468142425Snectar
469142425Snectartest:   tests
470142425Snectar
471142425Snectartests: rehash
472142425Snectar	@(cd test && echo "testing..." && \
473238405Sjkim	$(CLEARENV) && $(MAKE) -e $(BUILDENV) TOP=.. TESTS='$(TESTS)' OPENSSL_DEBUG_MEMORY=on OPENSSL_CONF=../apps/openssl.cnf tests );
474238405Sjkim	OPENSSL_CONF=apps/openssl.cnf util/opensslwrap.sh version -a
475142425Snectar
476142425Snectarreport:
477142425Snectar	@$(PERL) util/selftest.pl
478142425Snectar
479284283Sjkimupdate: errors stacks util/libeay.num util/ssleay.num TABLE
480284283Sjkim	@set -e; target=update; $(RECURSIVE_BUILD_CMD)
481284283Sjkim
482142425Snectardepend:
483160814Ssimon	@set -e; target=depend; $(RECURSIVE_BUILD_CMD)
484142425Snectar
485142425Snectarlint:
486160814Ssimon	@set -e; target=lint; $(RECURSIVE_BUILD_CMD)
487142425Snectar
488142425Snectartags:
489142425Snectar	rm -f TAGS
490142425Snectar	find . -name '[^.]*.[ch]' | xargs etags -a
491142425Snectar
492142425Snectarerrors:
493238405Sjkim	$(PERL) util/ck_errf.pl -strict */*.c */*/*.c
494142425Snectar	$(PERL) util/mkerr.pl -recurse -write
495160814Ssimon	(cd engines; $(MAKE) PERL=$(PERL) errors)
496142425Snectar
497142425Snectarstacks:
498142425Snectar	$(PERL) util/mkstack.pl -write
499142425Snectar
500142425Snectarutil/libeay.num::
501142425Snectar	$(PERL) util/mkdef.pl crypto update
502142425Snectar
503142425Snectarutil/ssleay.num::
504142425Snectar	$(PERL) util/mkdef.pl ssl update
505142425Snectar
506142425SnectarTABLE: Configure
507142425Snectar	(echo 'Output of `Configure TABLE'"':"; \
508142425Snectar	$(PERL) Configure TABLE) > TABLE
509142425Snectar
510142425Snectar# Build distribution tar-file. As the list of files returned by "find" is
511142425Snectar# pretty long, on several platforms a "too many arguments" error or similar
512142425Snectar# would occur. Therefore the list of files is temporarily stored into a file
513142425Snectar# and read directly, requiring GNU-Tar. Call "make TAR=gtar dist" if the normal
514142425Snectar# tar does not support the --files-from option.
515295009SjkimTAR_COMMAND=$(TAR) $(TARFLAGS) --files-from $(TARFILE).list \
516295009Sjkim	                       --owner 0 --group 0 \
517295009Sjkim			       --transform 's|^|$(NAME)/|' \
518291719Sjkim			       -cvf -
519291719Sjkim
520295009Sjkim$(TARFILE).list:
521291719Sjkim	find * \! -name STATUS \! -name TABLE \! -name '*.o' \! -name '*.a' \
522291719Sjkim	       \! -name '*.so' \! -name '*.so.*'  \! -name 'openssl' \
523295009Sjkim	       \( \! -name '*test' -o -name bctest -o -name pod2mantest \) \
524344604Sjkim	       \! -name '.#*' \! -name '*.bak' \! -name '*~' \! -type l \
525295009Sjkim	    | sort > $(TARFILE).list
526291719Sjkim
527295009Sjkimtar: $(TARFILE).list
528142425Snectar	find . -type d -print | xargs chmod 755
529142425Snectar	find . -type f -print | xargs chmod a+r
530142425Snectar	find . -type f -perm -0100 -print | xargs chmod a+x
531295009Sjkim	$(TAR_COMMAND) | gzip --best > $(TARFILE).gz
532295009Sjkim	rm -f $(TARFILE).list
533295009Sjkim	ls -l $(TARFILE).gz
534142425Snectar
535295009Sjkimtar-snap: $(TARFILE).list
536295009Sjkim	$(TAR_COMMAND) > $(TARFILE)
537295009Sjkim	rm -f $(TARFILE).list
538295009Sjkim	ls -l $(TARFILE)
539142425Snectar
540142425Snectardist:   
541142425Snectar	$(PERL) Configure dist
542238405Sjkim	@$(MAKE) SDIRS='$(SDIRS)' clean
543295009Sjkim	@$(MAKE) TAR='$(TAR)' TARFLAGS='$(TARFLAGS)' $(DISTTARVARS) tar
544142425Snectar
545142425Snectarinstall: all install_docs install_sw
546142425Snectar
547142425Snectarinstall_sw:
548142425Snectar	@$(PERL) $(TOP)/util/mkdir-p.pl $(INSTALL_PREFIX)$(INSTALLTOP)/bin \
549205128Ssimon		$(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR) \
550205128Ssimon		$(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines \
551205128Ssimon		$(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig \
552142425Snectar		$(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl \
553142425Snectar		$(INSTALL_PREFIX)$(OPENSSLDIR)/misc \
554142425Snectar		$(INSTALL_PREFIX)$(OPENSSLDIR)/certs \
555142425Snectar		$(INSTALL_PREFIX)$(OPENSSLDIR)/private
556160814Ssimon	@set -e; headerlist="$(EXHEADER)"; for i in $$headerlist;\
557142425Snectar	do \
558142425Snectar	(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
559142425Snectar	chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
560142425Snectar	done;
561160814Ssimon	@set -e; target=install; $(RECURSIVE_BUILD_CMD)
562238405Sjkim	@set -e; liblist="$(LIBS)"; for i in $$liblist ;\
563142425Snectar	do \
564142425Snectar		if [ -f "$$i" ]; then \
565142425Snectar		(       echo installing $$i; \
566205128Ssimon			cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
567205128Ssimon			$(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
568205128Ssimon			chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
569205128Ssimon			mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i ); \
570142425Snectar		fi; \
571142425Snectar	done;
572160814Ssimon	@set -e; if [ -n "$(SHARED_LIBS)" ]; then \
573142425Snectar		tmp="$(SHARED_LIBS)"; \
574142425Snectar		for i in $${tmp:-x}; \
575142425Snectar		do \
576142425Snectar			if [ -f "$$i" -o -f "$$i.a" ]; then \
577142425Snectar			(       echo installing $$i; \
578290207Sjkim				if expr "$(PLATFORM)" : "Cygwin" >/dev/null; then \
579160814Ssimon					c=`echo $$i | sed 's/^lib\(.*\)\.dll\.a/cyg\1-$(SHLIB_VERSION_NUMBER).dll/'`; \
580142425Snectar					cp $$c $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
581142425Snectar					chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
582142425Snectar					mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c; \
583205128Ssimon					cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
584205128Ssimon					chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
585205128Ssimon					mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i; \
586290207Sjkim				else \
587290207Sjkim					cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
588290207Sjkim					chmod 555 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
589290207Sjkim					mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i; \
590142425Snectar				fi ); \
591238405Sjkim				if expr $(PLATFORM) : 'mingw' > /dev/null; then \
592238405Sjkim				(	case $$i in \
593238405Sjkim						*crypto*) i=libeay32.dll;; \
594238405Sjkim						*ssl*)    i=ssleay32.dll;; \
595238405Sjkim					esac; \
596238405Sjkim					echo installing $$i; \
597238405Sjkim	 				cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new; \
598238405Sjkim	 				chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new; \
599238405Sjkim	 				mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i ); \
600238405Sjkim				fi; \
601142425Snectar			fi; \
602142425Snectar		done; \
603142425Snectar		(	here="`pwd`"; \
604205128Ssimon			cd $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR); \
605160814Ssimon			$(MAKE) -f $$here/Makefile HERE="$$here" link-shared ); \
606142425Snectar		if [ "$(INSTALLTOP)" != "/usr" ]; then \
607142425Snectar			echo 'OpenSSL shared libraries have been installed in:'; \
608142425Snectar			echo '  $(INSTALLTOP)'; \
609142425Snectar			echo ''; \
610142425Snectar			sed -e '1,/^$$/d' doc/openssl-shared.txt; \
611142425Snectar		fi; \
612142425Snectar	fi
613205128Ssimon	cp libcrypto.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
614205128Ssimon	chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/libcrypto.pc
615205128Ssimon	cp libssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
616205128Ssimon	chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/libssl.pc
617205128Ssimon	cp openssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
618205128Ssimon	chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/openssl.pc
619142425Snectar
620238405Sjkiminstall_html_docs:
621238405Sjkim	here="`pwd`"; \
622290207Sjkim	filecase=; \
623290207Sjkim	case "$(PLATFORM)" in DJGPP|Cygwin*|mingw*|darwin*-*-cc) \
624290207Sjkim		filecase=-i; \
625290207Sjkim	esac; \
626238405Sjkim	for subdir in apps crypto ssl; do \
627238405Sjkim		mkdir -p $(INSTALL_PREFIX)$(HTMLDIR)/$$subdir; \
628238405Sjkim		for i in doc/$$subdir/*.pod; do \
629238405Sjkim			fn=`basename $$i .pod`; \
630238405Sjkim			echo "installing html/$$fn.$(HTMLSUFFIX)"; \
631238405Sjkim			cat $$i \
632238405Sjkim			| sed -r 's/L<([^)]*)(\([0-9]\))?\|([^)]*)(\([0-9]\))?>/L<\1|\3>/g' \
633238405Sjkim			| pod2html --podroot=doc --htmlroot=.. --podpath=apps:crypto:ssl \
634238405Sjkim			| sed -r 's/<!DOCTYPE.*//g' \
635238405Sjkim			> $(INSTALL_PREFIX)$(HTMLDIR)/$$subdir/$$fn.$(HTMLSUFFIX); \
636238405Sjkim			$(PERL) util/extract-names.pl < $$i | \
637238405Sjkim				grep -v $$filecase "^$$fn\$$" | \
638238405Sjkim				(cd $(INSTALL_PREFIX)$(HTMLDIR)/$$subdir; \
639238405Sjkim				 while read n; do \
640238405Sjkim					PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$(HTMLSUFFIX) "$$n".$(HTMLSUFFIX); \
641238405Sjkim				 done); \
642238405Sjkim		done; \
643238405Sjkim	done
644238405Sjkim
645142425Snectarinstall_docs:
646142425Snectar	@$(PERL) $(TOP)/util/mkdir-p.pl \
647142425Snectar		$(INSTALL_PREFIX)$(MANDIR)/man1 \
648142425Snectar		$(INSTALL_PREFIX)$(MANDIR)/man3 \
649142425Snectar		$(INSTALL_PREFIX)$(MANDIR)/man5 \
650142425Snectar		$(INSTALL_PREFIX)$(MANDIR)/man7
651205128Ssimon	@pod2man="`cd ./util; ./pod2mantest $(PERL)`"; \
652142425Snectar	here="`pwd`"; \
653142425Snectar	filecase=; \
654290207Sjkim	case "$(PLATFORM)" in DJGPP|Cygwin*|mingw*|darwin*-*-cc) \
655142425Snectar		filecase=-i; \
656290207Sjkim	esac; \
657160814Ssimon	set -e; for i in doc/apps/*.pod; do \
658142425Snectar		fn=`basename $$i .pod`; \
659160814Ssimon		sec=`$(PERL) util/extract-section.pl 1 < $$i`; \
660142425Snectar		echo "installing man$$sec/$$fn.$${sec}$(MANSUFFIX)"; \
661142425Snectar		(cd `$(PERL) util/dirname.pl $$i`; \
662142425Snectar		sh -c "$$pod2man \
663142425Snectar			--section=$$sec --center=OpenSSL \
664142425Snectar			--release=$(VERSION) `basename $$i`") \
665142425Snectar			>  $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$${sec}$(MANSUFFIX); \
666142425Snectar		$(PERL) util/extract-names.pl < $$i | \
667160814Ssimon			(grep -v $$filecase "^$$fn\$$"; true) | \
668160814Ssimon			(grep -v "[	]"; true) | \
669142425Snectar			(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
670142425Snectar			 while read n; do \
671238405Sjkim				PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
672142425Snectar			 done); \
673142425Snectar	done; \
674160814Ssimon	set -e; for i in doc/crypto/*.pod doc/ssl/*.pod; do \
675142425Snectar		fn=`basename $$i .pod`; \
676160814Ssimon		sec=`$(PERL) util/extract-section.pl 3 < $$i`; \
677142425Snectar		echo "installing man$$sec/$$fn.$${sec}$(MANSUFFIX)"; \
678142425Snectar		(cd `$(PERL) util/dirname.pl $$i`; \
679142425Snectar		sh -c "$$pod2man \
680142425Snectar			--section=$$sec --center=OpenSSL \
681142425Snectar			--release=$(VERSION) `basename $$i`") \
682142425Snectar			>  $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$${sec}$(MANSUFFIX); \
683142425Snectar		$(PERL) util/extract-names.pl < $$i | \
684160814Ssimon			(grep -v $$filecase "^$$fn\$$"; true) | \
685160814Ssimon			(grep -v "[	]"; true) | \
686142425Snectar			(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
687142425Snectar			 while read n; do \
688238405Sjkim				PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
689142425Snectar			 done); \
690142425Snectar	done
691142425Snectar
692142425Snectar# DO NOT DELETE THIS LINE -- make depend depends on it.
693