annotate OrthancFramework/Resources/CMake/OpenSslConfigurationStatic-3.0.cmake @ 5161:b6dc4606ab04

release notes for 1.11.3
author Alain Mazy <am@osimis.io>
date Fri, 03 Feb 2023 14:24:43 +0100
parents 4ed25a8bac39
children 993a6b23f032
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 # Orthanc - A Lightweight, RESTful DICOM Store
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 # Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 # Department, University Hospital of Liege, Belgium
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 # Copyright (C) 2017-2021 Osimis S.A., Belgium
4862
0a5d05637701 added missing copyright
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4861
diff changeset
5 # Copyright (C) 2021-2021 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 #
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 # This program is free software: you can redistribute it and/or
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 # modify it under the terms of the GNU Lesser General Public License
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 # as published by the Free Software Foundation, either version 3 of
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 # the License, or (at your option) any later version.
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 #
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 # This program is distributed in the hope that it will be useful, but
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 # Lesser General Public License for more details.
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 #
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 # You should have received a copy of the GNU Lesser General Public
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 # License along with this program. If not, see
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 # <http://www.gnu.org/licenses/>.
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22 set(OPENSSL_VERSION_MAJOR 3)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23 set(OPENSSL_VERSION_MINOR 0)
5068
02fae039a15d upgrade to openssl 3.0.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4869
diff changeset
24 set(OPENSSL_VERSION_PATCH 5)
4861
d1aae7c3dd5d upgraded openssl to 3.0.1
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4705
diff changeset
25 set(OPENSSL_VERSION_PRE_RELEASE "")
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26 set(OPENSSL_VERSION_FULL "${OPENSSL_VERSION_MAJOR}.${OPENSSL_VERSION_MINOR}.${OPENSSL_VERSION_PATCH}${OPENSSL_VERSION_PRE_RELEASE}")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 SET(OPENSSL_SOURCES_DIR ${CMAKE_BINARY_DIR}/openssl-${OPENSSL_VERSION_FULL})
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 SET(OPENSSL_URL "http://orthanc.osimis.io/ThirdPartyDownloads/openssl-${OPENSSL_VERSION_FULL}.tar.gz")
5068
02fae039a15d upgrade to openssl 3.0.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4869
diff changeset
29 SET(OPENSSL_MD5 "163bb3e58c143793d1dc6a6ec7d185d5")
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 if (IS_DIRECTORY "${OPENSSL_SOURCES_DIR}")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 set(FirstRun OFF)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 else()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 set(FirstRun ON)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 DownloadPackage(${OPENSSL_MD5} ${OPENSSL_URL} "${OPENSSL_SOURCES_DIR}")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40 if (FirstRun)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41 # Apply the patches
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 execute_process(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43 COMMAND ${PATCH_EXECUTABLE} -p0 -N -i
4861
d1aae7c3dd5d upgraded openssl to 3.0.1
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4705
diff changeset
44 ${CMAKE_CURRENT_LIST_DIR}/../Patches/openssl-${OPENSSL_VERSION_FULL}.patch
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 RESULT_VARIABLE Failure
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 if (Failure)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 message(FATAL_ERROR "Error while patching a file")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53 execute_process(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 COMMAND ${PYTHON_EXECUTABLE}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 ${CMAKE_CURRENT_LIST_DIR}/../Patches/OpenSSL-ConfigureHeaders.py
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 "${OPENSSL_SOURCES_DIR}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 RESULT_VARIABLE Failure
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60 if (Failure)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 message(FATAL_ERROR "Error while configuring the OpenSSL headers")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 file(WRITE ${OPENSSL_SOURCES_DIR}/include/openssl/opensslv.h "")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65 file(WRITE ${OPENSSL_SOURCES_DIR}/include/crypto/bn_conf.h "")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66 file(WRITE ${OPENSSL_SOURCES_DIR}/include/crypto/dso_conf.h "")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
68 file(WRITE ${OPENSSL_SOURCES_DIR}/crypto/buildinf.h "
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
69 #define DATE \"\"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
70 #define PLATFORM \"\"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
71 #define compiler_flags \"\"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
72 ")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
73
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
74 else()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
75 message("The patches for OpenSSL have already been applied")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
76 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
77
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
78
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
79 if (OPENSSL_VERSION_PRE_RELEASE STREQUAL "")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
80 set(VERSION_VERSION_OFFSET 0)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
81 else()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
82 set(VERSION_VERSION_OFFSET 15)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
83 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
84
4861
d1aae7c3dd5d upgraded openssl to 3.0.1
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4705
diff changeset
85 math(EXPR OPENSSL_CONFIGURED_API "${OPENSSL_VERSION_MAJOR} * 10000 + ${OPENSSL_VERSION_MINOR} * 100")
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
86
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
87 # This macro is normally defined in "opensslv.h.in"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
88 math(EXPR OPENSSL_VERSION_NUMBER "(${OPENSSL_VERSION_MAJOR} << 28) + (${OPENSSL_VERSION_MINOR} << 20) + (${OPENSSL_VERSION_PATCH} << 4) + ${VERSION_VERSION_OFFSET}")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
89
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
90 list(GET CMAKE_FIND_LIBRARY_SUFFIXES 0 OPENSSL_DSO_EXTENSION)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
91
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
92 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
93 -DOPENSSL_VERSION_MAJOR=${OPENSSL_VERSION_MAJOR}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
94 -DOPENSSL_VERSION_MINOR=${OPENSSL_VERSION_MINOR}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
95 -DOPENSSL_VERSION_PATCH=${OPENSSL_VERSION_PATCH}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
96 -DOPENSSL_CONFIGURED_API=${OPENSSL_CONFIGURED_API}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
97 -DOPENSSL_VERSION_NUMBER=${OPENSSL_VERSION_NUMBER}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
98 -DOPENSSL_VERSION_PRE_RELEASE="${OPENSSL_VERSION_PRE_RELEASE}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
99 -DOPENSSL_VERSION_BUILD_METADATA=""
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
100 -DOPENSSL_VERSION_TEXT="OpenSSL ${OPENSSL_VERSION_FULL}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
101 -DOPENSSL_VERSION_STR="${OPENSSL_VERSION_MAJOR}.${OPENSSL_VERSION_MINOR}.${OPENSSL_VERSION_PATCH}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
102 -DOPENSSL_FULL_VERSION_STR="${OPENSSL_VERSION_FULL}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
103 -DDSO_EXTENSION="${OPENSSL_DSO_EXTENSION}"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
104
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
105 -DOPENSSLDIR="/usr/local/ssl"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
106 -DMODULESDIR="" # TODO
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
107
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
108 -DOPENSSL_BUILDING_OPENSSL
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
109 -DOPENSSL_THREADS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
110 -DOPENSSL_IA32_SSE2
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
111
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
112 -DOPENSSL_NO_AFALGENG
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
113 -DOPENSSL_NO_ASM
4867
82612f07226a added -DOPENSSL_NO_CHACHA
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
114 -DOPENSSL_NO_CHACHA # Necessary for VC2015-64 since openssl-3.0.1
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
115 -DOPENSSL_NO_DEVCRYPTOENG
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
116 -DOPENSSL_NO_DYNAMIC_ENGINE
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
117 -DOPENSSL_NO_EC_NISTP_64_GCC_128
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
118 -DOPENSSL_NO_GOST
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
119 -DOPENSSL_NO_RFC3779
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
120 -DOPENSSL_NO_SCTP
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
121
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
122 -DOPENSSL_NO_KTLS # TODO ?
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
123 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
124
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
125
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
126 include_directories(
5070
4ed25a8bac39 test fix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5068
diff changeset
127 BEFORE
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
128 ${OPENSSL_SOURCES_DIR}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
129 ${OPENSSL_SOURCES_DIR}/crypto/asn1
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
130 ${OPENSSL_SOURCES_DIR}/crypto/ec/curve448
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
131 ${OPENSSL_SOURCES_DIR}/crypto/ec/curve448/arch_32
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
132 ${OPENSSL_SOURCES_DIR}/crypto/evp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
133 ${OPENSSL_SOURCES_DIR}/crypto/include
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
134 ${OPENSSL_SOURCES_DIR}/crypto/modes
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
135 ${OPENSSL_SOURCES_DIR}/include
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
136 ${OPENSSL_SOURCES_DIR}/providers/common/include
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
137 ${OPENSSL_SOURCES_DIR}/providers/implementations/include
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
138 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
139
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
140
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
141 set(OPENSSL_SOURCES_SUBDIRS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
142 ## Assembly is disabled
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
143 # ${OPENSSL_SOURCES_DIR}/crypto/aes/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
144 # ${OPENSSL_SOURCES_DIR}/crypto/bf/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
145 # ${OPENSSL_SOURCES_DIR}/crypto/bn/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
146 # ${OPENSSL_SOURCES_DIR}/crypto/camellia/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
147 # ${OPENSSL_SOURCES_DIR}/crypto/cast/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
148 # ${OPENSSL_SOURCES_DIR}/crypto/chacha/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
149 # ${OPENSSL_SOURCES_DIR}/crypto/des/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
150 # ${OPENSSL_SOURCES_DIR}/crypto/ec/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
151 # ${OPENSSL_SOURCES_DIR}/crypto/md5/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
152 # ${OPENSSL_SOURCES_DIR}/crypto/modes/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
153 # ${OPENSSL_SOURCES_DIR}/crypto/poly1305/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
154 # ${OPENSSL_SOURCES_DIR}/crypto/rc4/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
155 # ${OPENSSL_SOURCES_DIR}/crypto/rc5/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
156 # ${OPENSSL_SOURCES_DIR}/crypto/ripemd/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
157 # ${OPENSSL_SOURCES_DIR}/crypto/sha/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
158 # ${OPENSSL_SOURCES_DIR}/crypto/whrlpool/asm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
159
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
160 ${OPENSSL_SOURCES_DIR}/crypto
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
161 ${OPENSSL_SOURCES_DIR}/crypto/aes
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
162 ${OPENSSL_SOURCES_DIR}/crypto/aria
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
163 ${OPENSSL_SOURCES_DIR}/crypto/asn1
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
164 ${OPENSSL_SOURCES_DIR}/crypto/async
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
165 ${OPENSSL_SOURCES_DIR}/crypto/async/arch
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
166 ${OPENSSL_SOURCES_DIR}/crypto/bf
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
167 ${OPENSSL_SOURCES_DIR}/crypto/bio
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
168 ${OPENSSL_SOURCES_DIR}/crypto/bn
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
169 ${OPENSSL_SOURCES_DIR}/crypto/buffer
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
170 ${OPENSSL_SOURCES_DIR}/crypto/camellia
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
171 ${OPENSSL_SOURCES_DIR}/crypto/cast
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
172 ${OPENSSL_SOURCES_DIR}/crypto/chacha
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
173 ${OPENSSL_SOURCES_DIR}/crypto/cmac
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
174 ${OPENSSL_SOURCES_DIR}/crypto/cmp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
175 ${OPENSSL_SOURCES_DIR}/crypto/cms
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
176 ${OPENSSL_SOURCES_DIR}/crypto/comp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
177 ${OPENSSL_SOURCES_DIR}/crypto/conf
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
178 ${OPENSSL_SOURCES_DIR}/crypto/crmf
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
179 ${OPENSSL_SOURCES_DIR}/crypto/ct
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
180 ${OPENSSL_SOURCES_DIR}/crypto/des
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
181 ${OPENSSL_SOURCES_DIR}/crypto/dh
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
182 ${OPENSSL_SOURCES_DIR}/crypto/dsa
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
183 ${OPENSSL_SOURCES_DIR}/crypto/dso
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
184 ${OPENSSL_SOURCES_DIR}/crypto/ec
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
185 ${OPENSSL_SOURCES_DIR}/crypto/ec/curve448
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
186 ${OPENSSL_SOURCES_DIR}/crypto/ec/curve448/arch_32
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
187 ${OPENSSL_SOURCES_DIR}/crypto/ec/curve448/arch_64
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
188 ${OPENSSL_SOURCES_DIR}/crypto/encode_decode
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
189 ${OPENSSL_SOURCES_DIR}/crypto/engine
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
190 ${OPENSSL_SOURCES_DIR}/crypto/err
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
191 ${OPENSSL_SOURCES_DIR}/crypto/ess
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
192 ${OPENSSL_SOURCES_DIR}/crypto/evp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
193 ${OPENSSL_SOURCES_DIR}/crypto/ffc
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
194 ${OPENSSL_SOURCES_DIR}/crypto/hmac
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
195 ${OPENSSL_SOURCES_DIR}/crypto/http
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
196 ${OPENSSL_SOURCES_DIR}/crypto/idea
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
197 ${OPENSSL_SOURCES_DIR}/crypto/kdf
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
198 ${OPENSSL_SOURCES_DIR}/crypto/lhash
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
199 ${OPENSSL_SOURCES_DIR}/crypto/md2
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
200 ${OPENSSL_SOURCES_DIR}/crypto/md4
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
201 ${OPENSSL_SOURCES_DIR}/crypto/md5
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
202 ${OPENSSL_SOURCES_DIR}/crypto/mdc2
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
203 ${OPENSSL_SOURCES_DIR}/crypto/modes
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
204 ${OPENSSL_SOURCES_DIR}/crypto/objects
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
205 ${OPENSSL_SOURCES_DIR}/crypto/ocsp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
206 ${OPENSSL_SOURCES_DIR}/crypto/pem
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
207 ${OPENSSL_SOURCES_DIR}/crypto/perlasm
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
208 ${OPENSSL_SOURCES_DIR}/crypto/pkcs12
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
209 ${OPENSSL_SOURCES_DIR}/crypto/pkcs7
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
210 ${OPENSSL_SOURCES_DIR}/crypto/poly1305
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
211 ${OPENSSL_SOURCES_DIR}/crypto/property
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
212 ${OPENSSL_SOURCES_DIR}/crypto/rand
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
213 ${OPENSSL_SOURCES_DIR}/crypto/rc2
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
214 ${OPENSSL_SOURCES_DIR}/crypto/rc4
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
215 ${OPENSSL_SOURCES_DIR}/crypto/rc5
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
216 ${OPENSSL_SOURCES_DIR}/crypto/ripemd
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
217 ${OPENSSL_SOURCES_DIR}/crypto/rsa
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
218 ${OPENSSL_SOURCES_DIR}/crypto/seed
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
219 ${OPENSSL_SOURCES_DIR}/crypto/sha
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
220 ${OPENSSL_SOURCES_DIR}/crypto/siphash
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
221 ${OPENSSL_SOURCES_DIR}/crypto/sm2
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
222 ${OPENSSL_SOURCES_DIR}/crypto/sm3
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
223 ${OPENSSL_SOURCES_DIR}/crypto/sm4
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
224 ${OPENSSL_SOURCES_DIR}/crypto/srp
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
225 ${OPENSSL_SOURCES_DIR}/crypto/stack
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
226 ${OPENSSL_SOURCES_DIR}/crypto/store
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
227 ${OPENSSL_SOURCES_DIR}/crypto/ts
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
228 ${OPENSSL_SOURCES_DIR}/crypto/txt_db
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
229 ${OPENSSL_SOURCES_DIR}/crypto/ui
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
230 ${OPENSSL_SOURCES_DIR}/crypto/whrlpool
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
231 ${OPENSSL_SOURCES_DIR}/crypto/x509
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
232
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
233 # ${OPENSSL_SOURCES_DIR}/providers/implementations/rands/seeding # OS-specific
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
234 ${OPENSSL_SOURCES_DIR}/providers
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
235 ${OPENSSL_SOURCES_DIR}/providers/common
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
236 ${OPENSSL_SOURCES_DIR}/providers/common/der
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
237 ${OPENSSL_SOURCES_DIR}/providers/implementations/asymciphers
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
238 ${OPENSSL_SOURCES_DIR}/providers/implementations/ciphers
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
239 ${OPENSSL_SOURCES_DIR}/providers/implementations/digests
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
240 ${OPENSSL_SOURCES_DIR}/providers/implementations/encode_decode
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
241 ${OPENSSL_SOURCES_DIR}/providers/implementations/exchange
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
242 ${OPENSSL_SOURCES_DIR}/providers/implementations/kdfs
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
243 ${OPENSSL_SOURCES_DIR}/providers/implementations/kem
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
244 ${OPENSSL_SOURCES_DIR}/providers/implementations/keymgmt
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
245 ${OPENSSL_SOURCES_DIR}/providers/implementations/macs
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
246 ${OPENSSL_SOURCES_DIR}/providers/implementations/rands
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
247 ${OPENSSL_SOURCES_DIR}/providers/implementations/signature
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
248 ${OPENSSL_SOURCES_DIR}/providers/implementations/storemgmt
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
249
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
250 ${OPENSSL_SOURCES_DIR}/ssl
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
251 ${OPENSSL_SOURCES_DIR}/ssl/record
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
252 ${OPENSSL_SOURCES_DIR}/ssl/statem
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
253 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
254
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
255 if (ENABLE_OPENSSL_ENGINES)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
256 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
257 #-DENGINESDIR="/usr/local/lib/engines-1.1" # On GNU/Linux
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
258 -DENGINESDIR="."
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
259 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
260
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
261 list(APPEND OPENSSL_SOURCES_SUBDIRS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
262 ${OPENSSL_SOURCES_DIR}/engines
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
263 ${OPENSSL_SOURCES_DIR}/crypto/engine
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
264 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
265 else()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
266 add_definitions(-DOPENSSL_NO_ENGINE)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
267 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
268
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
269 list(APPEND OPENSSL_SOURCES_SUBDIRS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
270 # EC, ECDH and ECDSA are necessary for PKCS11, and for contacting
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
271 # HTTPS servers that use TLS certificate encrypted with ECDSA
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
272 # (check the output of a recent version of the "sslscan"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
273 # command). Until Orthanc <= 1.4.1, these features were only
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
274 # enabled if ENABLE_PKCS11 support was set to "ON".
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
275 # https://groups.google.com/d/msg/orthanc-users/2l-bhYIMEWg/oMmK33bYBgAJ
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
276 ${OPENSSL_SOURCES_DIR}/crypto/ec
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
277 ${OPENSSL_SOURCES_DIR}/crypto/ecdh
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
278 ${OPENSSL_SOURCES_DIR}/crypto/ecdsa
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
279 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
280
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
281 foreach(d ${OPENSSL_SOURCES_SUBDIRS})
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
282 AUX_SOURCE_DIRECTORY(${d} OPENSSL_SOURCES)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
283 endforeach()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
284
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
285
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
286 list(REMOVE_ITEM OPENSSL_SOURCES
4705
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
287 # Files below are not part of the "libcrypto.a" and "libssl.a" that
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
288 # are created by compiling OpenSSL from sources
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
289 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_nyi.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
290 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_unix.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
291 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_vms.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
292 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_win.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
293 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_win32.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
294 ${OPENSSL_SOURCES_DIR}/crypto/LPdir_wince.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
295 ${OPENSSL_SOURCES_DIR}/crypto/aes/aes_x86core.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
296 ${OPENSSL_SOURCES_DIR}/crypto/armcap.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
297 ${OPENSSL_SOURCES_DIR}/crypto/des/ncbc_enc.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
298 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_nistp224.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
299 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_nistp256.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
300 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_nistp521.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
301 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_nistz256.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
302 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_nistz256_table.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
303 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_s390x_nistp.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
304 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecx_s390x.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
305 ${OPENSSL_SOURCES_DIR}/crypto/poly1305/poly1305_base2_44.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
306 ${OPENSSL_SOURCES_DIR}/crypto/rsa/rsa_acvp_test_params.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
307 ${OPENSSL_SOURCES_DIR}/crypto/s390xcap.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
308 ${OPENSSL_SOURCES_DIR}/engines/e_devcrypto.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
309 ${OPENSSL_SOURCES_DIR}/engines/e_loader_attic.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
310 ${OPENSSL_SOURCES_DIR}/providers/common/securitycheck_fips.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
311 ${OPENSSL_SOURCES_DIR}/providers/implementations/macs/blake2_mac_impl.c
4705
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
312
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
313 ${OPENSSL_SOURCES_DIR}/engines/e_afalg.c # Fails on OS X and Visual Studio
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
314 ${OPENSSL_SOURCES_DIR}/crypto/poly1305/poly1305_ieee754.c # Fails on Visual Studio
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
315
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
316 ${OPENSSL_SOURCES_DIR}/ssl/ktls.c # TODO ?
4868
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
317
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
318 # Disable PowerPC sources
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
319 ${OPENSSL_SOURCES_DIR}/crypto/bn/bn_ppc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
320 ${OPENSSL_SOURCES_DIR}/crypto/chacha/chacha_ppc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
321 ${OPENSSL_SOURCES_DIR}/crypto/ec/ecp_ppc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
322 ${OPENSSL_SOURCES_DIR}/crypto/poly1305/poly1305_ppc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
323 ${OPENSSL_SOURCES_DIR}/crypto/ppccap.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
324 ${OPENSSL_SOURCES_DIR}/crypto/sha/sha_ppc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
325
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
326 # Disable SPARC sources
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
327 ${OPENSSL_SOURCES_DIR}/crypto/bn/bn_sparc.c
36587ae9e0e1 fix build of openssl bignum
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4862
diff changeset
328 ${OPENSSL_SOURCES_DIR}/crypto/sparcv9cap.c
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
329 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
330
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
331
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
332 if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux" OR
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
333 ${CMAKE_SYSTEM_NAME} STREQUAL "kFreeBSD" OR
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
334 ${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD" OR
4705
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
335 ${CMAKE_SYSTEM_NAME} STREQUAL "OpenBSD" OR
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
336 APPLE)
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
337 list(APPEND OPENSSL_SOURCES
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
338 ${OPENSSL_SOURCES_DIR}/providers/implementations/rands/seeding/rand_unix.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
339 )
4705
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
340 elseif("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows")
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
341 list(APPEND OPENSSL_SOURCES
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
342 ${OPENSSL_SOURCES_DIR}/providers/implementations/rands/seeding/rand_win.c
2b3db9d08fe2 fixes for OS X and Visual Studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4702
diff changeset
343 )
4702
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
344 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
345
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
346
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
347 # Check out "${OPENSSL_SOURCES_DIR}/Configurations/README.md": "This
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
348 # is default if no option is specified, it works on any supported
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
349 # system." It is mandatory to define it as a macro, as it is used by
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
350 # all the source files that include OpenSSL (e.g. "Core/Toolbox.cpp"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
351 # or curl)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
352 add_definitions(-DTHIRTY_TWO_BIT)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
353
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
354
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
355 if (NOT CMAKE_COMPILER_IS_GNUCXX OR
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
356 "${CMAKE_SYSTEM_NAME}" STREQUAL "Windows" OR
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
357 "${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
358 # Disable the use of a gcc extension, that is neither available on
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
359 # MinGW, nor on LSB
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
360 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
361 -DOPENSSL_NO_CRYPTO_MDEBUG_BACKTRACE
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
362 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
363 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
364
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
365
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
366 if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
367 set(OPENSSL_DEFINITIONS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
368 "${OPENSSL_DEFINITIONS};OPENSSL_SYSNAME_WIN32;SO_WIN32;WIN32_LEAN_AND_MEAN;L_ENDIAN;NO_WINDOWS_BRAINDEATH")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
369
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
370 if (ENABLE_OPENSSL_ENGINES)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
371 link_libraries(crypt32)
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
372 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
373
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
374 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
375 -DOPENSSL_RAND_SEED_OS # ${OPENSSL_SOURCES_DIR}/crypto/rand/rand_win.c
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
376 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
377
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
378 elseif ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase")
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
379 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
380 # In order for "crypto/mem_sec.c" to compile on LSB
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
381 -DOPENSSL_NO_SECURE_MEMORY
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
382
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
383 # The "OPENSSL_RAND_SEED_OS" value implies a syscall() to
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
384 # "__NR_getrandom" (i.e. system call "getentropy(2)") in
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
385 # "rand_unix.c", which is not available in LSB.
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
386 -DOPENSSL_RAND_SEED_DEVRANDOM
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
387
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
388 # If "OPENSSL_NO_ERR" is not defined, the PostgreSQL plugin
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
389 # crashes with segmentation fault in function
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
390 # "build_SYS_str_reasons()", that is called from
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
391 # "OPENSSL_init_ssl()"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
392 # https://bugs.orthanc-server.com/show_bug.cgi?id=193
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
393 -DOPENSSL_NO_ERR
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
394 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
395
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
396 else()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
397 # Fixes error "OpenSSL error: error:2406C06E:random number
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
398 # generator:RAND_DRBG_instantiate:error retrieving entropy" that was
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
399 # present in Orthanc 1.6.0, if statically linking on Ubuntu 18.04
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
400 add_definitions(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
401 -DOPENSSL_RAND_SEED_OS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
402 )
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
403 endif()
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
404
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
405
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
406 set_source_files_properties(
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
407 ${OPENSSL_SOURCES}
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
408 PROPERTIES COMPILE_DEFINITIONS
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
409 "${OPENSSL_DEFINITIONS};DSO_NONE"
312e0e29de90 compilation using openssl-3.0.0-beta1
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
410 )