update dev300-m58
[ooovba.git] / openssl / makefile.mk
blob68f16faf5c63953a6432fc87e82408d7a3ddd82e
1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 #
5 # Copyright 2008 by Sun Microsystems, Inc.
7 # OpenOffice.org - a multi-platform office productivity suite
9 # $RCSfile: makefile.mk,v $
11 # $Revision: 1.26 $
13 # This file is part of OpenOffice.org.
15 # OpenOffice.org is free software: you can redistribute it and/or modify
16 # it under the terms of the GNU Lesser General Public License version 3
17 # only, as published by the Free Software Foundation.
19 # OpenOffice.org is distributed in the hope that it will be useful,
20 # but WITHOUT ANY WARRANTY; without even the implied warranty of
21 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 # GNU Lesser General Public License version 3 for more details
23 # (a copy is included in the LICENSE file that accompanied this code).
25 # You should have received a copy of the GNU Lesser General Public License
26 # version 3 along with OpenOffice.org. If not, see
27 # <http://www.openoffice.org/license.html>
28 # for a copy of the LGPLv3 License.
30 #*************************************************************************
32 PRJ=.
34 PRJNAME=openssl
35 TARGET=openssl
37 # --- Settings -----------------------------------------------------
39 .INCLUDE : settings.mk
41 # --- Files --------------------------------------------------------
43 .IF "$(SYSTEM_OPENSSL)" == "YES"
44 @all:
45 @echo "Using system openssl...."
46 .ENDIF
48 .IF "$(DISABLE_OPENSSL)" == "TRUE"
49 @all:
50 @echo "openssl disabled...."
51 .ENDIF
53 OPENSSL_NAME=openssl-0.9.8k
55 TARFILE_NAME=$(OPENSSL_NAME)
57 CONFIGURE_DIR=.
58 CONFIGURE_ACTION=config
59 CONFIGURE_FLAGS=-I$(SYSBASE)$/usr$/include -L$(SYSBASE)$/usr$/lib shared no-idea
61 BUILD_DIR=.
62 BUILD_ACTION=make CC='$(CC)'
64 OUT2LIB = libssl.*
65 OUT2LIB += libcrypto.*
66 OUT2INC += include/openssl/*
68 .IF "$(OS)" == "LINUX"
69 PATCH_FILES=openssllnx.patch
70 ADDITIONAL_FILES:= \
71 libcrypto_OOo_0_9_8k.map \
72 libssl_OOo_0_9_8k.map
73 .IF "$(CPU)" == "X"
74 CONFIGURE_ACTION=Configure linux-generic64
75 .ELSE
76 CONFIGURE_ACTION=Configure linux-elf
77 .ENDIF
78 # if you build openssl as shared library you have to patch the Makefile.Shared "LD_LIBRARY_PATH=$$LD_LIBRARY_PATH \"
79 #BUILD_ACTION=make 'SHARED_LDFLAGS=-Wl,--version-script=./lib$$(SHLIBDIRS)_OOo_0_9_8e.map'
80 .ENDIF
82 .IF "$(OS)" == "SOLARIS"
83 PATCH_FILES=opensslsol.patch
84 ADDITIONAL_FILES:= \
85 libcrypto_OOo_0_9_8k.map \
86 libssl_OOo_0_9_8k.map
87 #BUILD_ACTION=make 'SHARED_LDFLAGS=-G -dy -z text -M./lib$$$$$$$$(SHLIBDIRS)_OOo_0_9_8e.map'
89 # We need a 64 BIT switch (currently I disable 64 Bit by default).
90 # Please replace this with a global switch if available
91 #USE_64 = 1
93 # Solaris INTEL
94 .IF "$(CPUNAME)" == "INTEL"
95 .IF "$(CPU)" == "X"
96 CONFIGURE_ACTION=Configure solaris64-x86_64-cc
97 .ELSE
98 CONFIGURE_ACTION=Configure solaris-x86-cc
99 .ENDIF
100 .ELSE
101 # Solaris SPARC
102 .IF "$(CPU)" == "U"
103 CONFIGURE_ACTION=Configure solaris64-sparcv9-cc
104 .ENDIF
105 .ENDIF
106 .ENDIF
108 .IF "$(OS)" == "WNT"
110 .IF "$(COM)"=="GCC"
111 PATCH_FILES=opensslmingw.patch
112 .IF "$(USE_MINGW)" == "cygwin"
113 CONFIGURE_ACTION=$(PERL) configure
114 CONFIGURE_FLAGS=mingw shared
115 INSTALL_ACTION=mv libcrypto.a libcrypto_static.a && mv libcrypto.dll.a libcrypto.a && mv libssl.a libssl_static.a && mv libssl.dll.a libssl.a
116 OUT2LIB = libcrypto_static.*
117 OUT2LIB += libssl_static.*
118 OUT2LIB += libcrypto.*
119 OUT2LIB += libssl.*
120 OUT2BIN = ssleay32.dll
121 OUT2BIN += libeay32.dll
122 .ELSE
123 CONFIGURE_ACTION=
124 BUILD_ACTION=cmd /c "ms\mingw32"
125 OUT2LIB = out/libcrypto_static.*
126 OUT2LIB += out/libssl_static.*
127 OUT2LIB += out/libcrypto.*
128 OUT2LIB += out/libssl.*
129 OUT2BIN = out/ssleay32.dll
130 OUT2BIN += out/libeay32.dll
131 .ENDIF
132 .ELSE
134 PATCH_FILES=openssl.patch
135 .IF "$(MAKETARGETS)" == ""
136 # The env. vars CC and PERL are used by nmake, and nmake insists on '\'s
137 # If WRAPCMD is set it is prepended before the compiler, don't touch that.
138 .IF "$(WRAPCMD)"==""
139 CC!:=$(subst,/,\ $(normpath,1 $(CC)))
140 .EXPORT : CC
141 .ENDIF
142 PERL_bak:=$(PERL)
143 PERL!:=$(subst,/,\ $(normpath,1 $(PERL)))
144 .EXPORT : PERL
145 PERL!:=$(PERL_bak)
146 .ENDIF
148 #CONFIGURE_ACTION=cmd /c $(PERL:s!\!/!) configure
149 CONFIGURE_ACTION=$(PERL) configure
150 CONFIGURE_FLAGS=VC-WIN32 no-idea
151 BUILD_ACTION=cmd /c "ms$(EMQ)\do_ms.bat $(subst,/,\ $(normpath,1 $(PERL)))" && nmake -f ms/ntdll.mak
153 OUT2LIB = out32dll$/ssleay32.lib
154 OUT2LIB += out32dll$/libeay32.lib
155 OUT2BIN = out32dll$/ssleay32.dll
156 OUT2BIN += out32dll$/libeay32.dll
157 OUT2INC = inc32$/openssl$/*
158 .ENDIF
159 .ENDIF
161 #set INCLUDE=D:\sol_temp\n\msvc7net3\PlatformSDK\include;D:\sol_temp\n\msvc7net3\include\ && set path=%path%;D:\sol_temp\r\btw\SRC680\perl\bin &&
163 # --- Targets ------------------------------------------------------
165 .INCLUDE : set_ext.mk
166 .INCLUDE : target.mk
167 .INCLUDE : tg_ext.mk