aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2020-05-09 00:16:39 +0200
committerDaniel Stenberg <daniel@haxx.se>2020-05-10 23:36:54 +0200
commit5d8c53d320acb585f72ad6298d8a18715771459f (patch)
treeeb17657e4153f1992218006e33cb1b8b6f9ca3ed
parent5bfc874a359c229adf82ab7495c8f7d28dea992e (diff)
CMake: add ENABLE_ALT_SVC option
Tested alt-svc with quiche. While at it, add missing MultiSSL reporting (not tested).
-rw-r--r--CMakeLists.txt5
-rw-r--r--lib/curl_config.h.cmake3
2 files changed, 8 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 616a70db6..224a09b1d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -745,6 +745,9 @@ else()
unset(USE_UNIX_SOCKETS CACHE)
endif()
+option(ENABLE_ALT_SVC "Enable alt-svc support" OFF)
+set(USE_ALTSVC ${ENABLE_ALT_SVC})
+
#
# CA handling
#
@@ -1312,6 +1315,7 @@ _add_if("Largefile" (CURL_SIZEOF_CURL_OFF_T GREATER 4) AND
# TODO SSP1 (WinSSL) check is missing
_add_if("SSPI" USE_WINDOWS_SSPI)
_add_if("GSS-API" HAVE_GSSAPI)
+_add_if("alt-svc" ENABLE_ALT_SVC)
# TODO SSP1 missing for SPNEGO
_add_if("SPNEGO" NOT CURL_DISABLE_CRYPTO_AUTH AND
(HAVE_GSSAPI OR USE_WINDOWS_SSPI))
@@ -1327,6 +1331,7 @@ _add_if("TLS-SRP" USE_TLS_SRP)
# TODO option --with-nghttp2 tests for nghttp2 lib and nghttp2/nghttp2.h header
_add_if("HTTP2" USE_NGHTTP2)
_add_if("HTTP3" USE_NGTCP2 OR USE_QUICHE)
+_add_if("MultiSSL" CURL_WITH_MULTI_SSL)
_add_if("HTTPS-proxy" SSL_ENABLED AND (USE_OPENSSL OR USE_GNUTLS OR USE_NSS))
string(REPLACE ";" " " SUPPORT_FEATURES "${_items}")
message(STATUS "Enabled features: ${SUPPORT_FEATURES}")
diff --git a/lib/curl_config.h.cmake b/lib/curl_config.h.cmake
index 7a77e9482..39160a9a8 100644
--- a/lib/curl_config.h.cmake
+++ b/lib/curl_config.h.cmake
@@ -1005,6 +1005,9 @@ ${SIZEOF_TIME_T_CODE}
/* if Unix domain sockets are enabled */
#cmakedefine USE_UNIX_SOCKETS
+/* to enable alt-svc */
+#cmakedefine USE_ALTSVC 1
+
/* Define to 1 if you are building a Windows target with large file support. */
#cmakedefine USE_WIN32_LARGE_FILES 1