aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@bootlin.com>2024-07-13 14:32:29 +0200
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>2024-07-13 14:41:36 +0200
commit3b5f0177ff2c3976863c520bb164d68fdde39ec0 (patch)
tree8c98debc5082254a90a2cd2e71838ccba288f5c1 /include
parent3d895bd51bf79afaaa168d076c65a71086582b60 (diff)
downloadportable-3b5f0177ff2c3976863c520bb164d68fdde39ec0.tar.gz
portable-3b5f0177ff2c3976863c520bb164d68fdde39ec0.tar.bz2
portable-3b5f0177ff2c3976863c520bb164d68fdde39ec0.zip
include/CMakeLists.txt: error out when architecture is not supported
Since commit b98c56fd5e86fa76eb55a98a2266a923f64f705c ("stop exposing hidden defines in public opensslconf.h"), only a subset of CPU architectures is supported by libressl. However, when a build is attempted for an unsupported architecture, it doesn't fail with a clear error message at configure time, but it fails with a weird error at build time: crypto/../include/openssl/rc4.h:75:9: error: unknown type name 'RC4_INT' In order to help users, let's bail out nicely at configure time with a good error message when the CPU architecture is not supported. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Diffstat (limited to 'include')
-rw-r--r--include/CMakeLists.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt
index 9d015cd..59f5b62 100644
--- a/include/CMakeLists.txt
+++ b/include/CMakeLists.txt
@@ -38,5 +38,7 @@ elseif(HOST_SPARC64)
38 file(READ arch/sparc64/opensslconf.h OPENSSLCONF) 38 file(READ arch/sparc64/opensslconf.h OPENSSLCONF)
39elseif(HOST_X86_64) 39elseif(HOST_X86_64)
40 file(READ arch/amd64/opensslconf.h OPENSSLCONF) 40 file(READ arch/amd64/opensslconf.h OPENSSLCONF)
41else()
42 message(FATAL_ERROR "Architecture not supported")
41endif() 43endif()
42file(WRITE ${CMAKE_BINARY_DIR}/include/openssl/opensslconf.h "${OPENSSLCONF}") 44file(WRITE ${CMAKE_BINARY_DIR}/include/openssl/opensslconf.h "${OPENSSLCONF}")