1 # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 $(eval
$(call gb_ExternalProject_ExternalProject
,openssl
))
12 $(eval
$(call gb_ExternalProject_register_targets
,openssl
,\
16 # For multi-line conditionals, align the $(if and the corresponding ),
17 # putting the latter on a line of its own. Also put the "else" comma
18 # on a line of its own. Hopefully should make the logic more clear.
21 $(if
$(filter LINUX FREEBSD ANDROID
,$(OS
)),\
22 $(if
$(filter INTEL
,$(CPUNAME
)),\
23 $(if
$(filter GNU
/kFreeBSD
,$(shell uname
)),debian-kfreebsd-i386
,linux-elf
)\
25 $(if
$(filter X86_64
,$(CPUNAME
)),\
26 $(if
$(filter GNU
/kFreeBSD
,$(shell uname
)),\
27 debian-kfreebsd-amd64\
29 $(if
$(filter TRUE
, $(ENABLE_DBGUTIL
)), debug-linux-generic64
, linux-generic64
) no-asm\
32 $(if
$(filter TRUE
, $(ENABLE_DBGUTIL
)), debug-linux-generic32
, linux-generic32
)\
36 $(if
$(filter SOLARIS
,$(OS
)),\
37 $(if
$(filter INTEL
,$(CPUNAME
)),solaris-x86-cc
,\
38 $(if
$(filter X86_64
,$(CPUNAME
)),solaris64-x86_64-cc
,solaris-sparcv9-cc
)\
41 $(if
$(filter IOS
,$(OS
)),\
44 $(if
$(filter WNT
,$(OS
)),\
45 $(if
$(filter INTEL
,$(CPUNAME
)),VC-WIN32
,VC-WIN64A
)\
47 $(if
$(filter MACOSX
,$(OS
)),\
48 $(if
$(filter POWERPC
,$(CPUNAME
)),darwin-ppc-cc
)\
49 $(if
$(filter INTEL
,$(CPUNAME
)),darwin-i386-cc
)\
50 $(if
$(filter X86_64
,$(CPUNAME
)),darwin64-x86_64-cc
)\
58 $(call gb_ExternalProject_get_state_target
,openssl
,build
):
59 $(call gb_ExternalProject_run
,build
,\
60 export CC
="$(shell cygpath -w $(filter-out -%,$(CC))) $(filter -%,$(CC))" \
61 && export PERL
="$(shell cygpath -w $(PERL))" \
62 && export LIB
="$(ILIB)" \
63 && $(PERL
) Configure
$(OPENSSL_PLATFORM
) no-idea \
64 && cmd
/c
"ms\do_ms.bat $(PERL) $(OPENSSL_PLATFORM)" \
66 && nmake
-f
"ms\ntdll.mak" \
67 && mv inc32
/* include/ \
71 $(call gb_ExternalProject_get_state_target
,openssl
,build
):
72 $(call gb_ExternalProject_run
,build
,\
74 $(if
$(filter LINUX MACOSX FREEBSD ANDROID SOLARIS IOS
,$(OS
)), \
76 $(if
$(filter WNT
,$(OS
)), \
79 $(OPENSSL_PLATFORM
) no-dso no-shared \
80 $(if
$(filter-out WNT
,$(OS
)),no-idea
) \
81 $(if
$(filter-out ANDROID IOS WNT
,$(OS
)), \
82 $(if
$(SYSBASE
),-I
$(SYSBASE
)/usr
/include -L
$(SYSBASE
)/usr
/lib
)) \
83 $(if
$(filter MACOSX
,$(OS
)),--prefix=/@.__________________________________________________OOO
) \
84 && $(MAKE
) build_libs \
86 $(if $(filter-out WNT MACOSX,$(OS)),-fvisibility=hidden)" \
90 # vim: set noet sw=4 ts=4: