@crossbind/port-curl-ios 2.0.0-beta.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +22 -0
- package/README.md +12 -0
- package/crossbind-port-curl.podspec +15 -0
- package/crossbind.build.js +1 -0
- package/crossbind.config.js +7 -0
- package/curl.xcframework/Info.plist +47 -0
- package/curl.xcframework/ios-arm64/Headers/curl/curl.h +3347 -0
- package/curl.xcframework/ios-arm64/Headers/curl/curlver.h +78 -0
- package/curl.xcframework/ios-arm64/Headers/curl/easy.h +123 -0
- package/curl.xcframework/ios-arm64/Headers/curl/header.h +74 -0
- package/curl.xcframework/ios-arm64/Headers/curl/mprintf.h +85 -0
- package/curl.xcframework/ios-arm64/Headers/curl/multi.h +560 -0
- package/curl.xcframework/ios-arm64/Headers/curl/options.h +70 -0
- package/curl.xcframework/ios-arm64/Headers/curl/stdcheaders.h +35 -0
- package/curl.xcframework/ios-arm64/Headers/curl/system.h +399 -0
- package/curl.xcframework/ios-arm64/Headers/curl/typecheck-gcc.h +960 -0
- package/curl.xcframework/ios-arm64/Headers/curl/urlapi.h +155 -0
- package/curl.xcframework/ios-arm64/Headers/curl/websockets.h +98 -0
- package/curl.xcframework/ios-arm64/libcurl.a +0 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/curl.h +3347 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/curlver.h +78 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/easy.h +123 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/header.h +74 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/mprintf.h +85 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/multi.h +560 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/options.h +70 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/stdcheaders.h +35 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/system.h +399 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/typecheck-gcc.h +960 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/urlapi.h +155 -0
- package/curl.xcframework/ios-arm64-simulator/Headers/curl/websockets.h +98 -0
- package/curl.xcframework/ios-arm64-simulator/libcurl.a +0 -0
- package/dist/prebuilt/CMakeLists.txt +57 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/crossbind-emccflags.fingerprint +1 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/curl.h +3347 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/curlver.h +78 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/easy.h +123 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/header.h +74 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/mprintf.h +85 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/multi.h +560 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/options.h +70 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/stdcheaders.h +35 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/system.h +399 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/typecheck-gcc.h +960 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/urlapi.h +155 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/include/curl/websockets.h +98 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/CURLConfig.cmake +220 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/CURLConfigVersion.cmake +71 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/CURLTargets-release.cmake +19 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/CURLTargets.cmake +108 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindBrotli.cmake +96 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindCares.cmake +132 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindGSS.cmake +264 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindGnuTLS.cmake +92 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLDAP.cmake +115 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibbacktrace.cmake +61 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibgsasl.cmake +91 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibidn2.cmake +92 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibpsl.cmake +92 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibssh.cmake +118 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibssh2.cmake +117 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindLibuv.cmake +102 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindMbedTLS.cmake +137 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindNGHTTP2.cmake +116 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindNGHTTP3.cmake +116 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindNGTCP2.cmake +187 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindNettle.cmake +97 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindQuiche.cmake +80 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindRustls.cmake +116 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindWolfSSL.cmake +135 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/cmake/CURL/FindZstd.cmake +144 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/libcurl.a +0 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/lib/pkgconfig/libcurl.pc +41 -0
- package/dist/prebuilt/ios-iphoneos-mt-release/share/man/man1/curl-config.1 +90 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/crossbind-emccflags.fingerprint +1 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/curl.h +3347 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/curlver.h +78 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/easy.h +123 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/header.h +74 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/mprintf.h +85 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/multi.h +560 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/options.h +70 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/stdcheaders.h +35 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/system.h +399 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/typecheck-gcc.h +960 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/urlapi.h +155 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/include/curl/websockets.h +98 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/CURLConfig.cmake +220 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/CURLConfigVersion.cmake +71 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/CURLTargets-release.cmake +19 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/CURLTargets.cmake +108 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindBrotli.cmake +96 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindCares.cmake +132 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindGSS.cmake +264 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindGnuTLS.cmake +92 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLDAP.cmake +115 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibbacktrace.cmake +61 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibgsasl.cmake +91 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibidn2.cmake +92 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibpsl.cmake +92 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibssh.cmake +118 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibssh2.cmake +117 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindLibuv.cmake +102 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindMbedTLS.cmake +137 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindNGHTTP2.cmake +116 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindNGHTTP3.cmake +116 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindNGTCP2.cmake +187 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindNettle.cmake +97 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindQuiche.cmake +80 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindRustls.cmake +116 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindWolfSSL.cmake +135 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/cmake/CURL/FindZstd.cmake +144 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/libcurl.a +0 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/lib/pkgconfig/libcurl.pc +41 -0
- package/dist/prebuilt/ios-iphonesimulator-mt-release/share/man/man1/curl-config.1 +90 -0
- package/package.json +34 -0
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
# Find the nettle library
|
|
25
|
+
#
|
|
26
|
+
# Input variables:
|
|
27
|
+
#
|
|
28
|
+
# - `NETTLE_INCLUDE_DIR`: Absolute path to nettle include directory.
|
|
29
|
+
# - `NETTLE_LIBRARY`: Absolute path to `nettle` library.
|
|
30
|
+
#
|
|
31
|
+
# Defines:
|
|
32
|
+
#
|
|
33
|
+
# - `NETTLE_FOUND`: System has nettle.
|
|
34
|
+
# - `NETTLE_VERSION`: Version of nettle.
|
|
35
|
+
# - `CURL::nettle`: nettle library target.
|
|
36
|
+
|
|
37
|
+
set(_nettle_pc_requires "nettle")
|
|
38
|
+
|
|
39
|
+
if(CURL_USE_PKGCONFIG AND
|
|
40
|
+
NOT DEFINED NETTLE_INCLUDE_DIR AND
|
|
41
|
+
NOT DEFINED NETTLE_LIBRARY)
|
|
42
|
+
find_package(PkgConfig QUIET)
|
|
43
|
+
pkg_check_modules(_nettle ${_nettle_pc_requires})
|
|
44
|
+
endif()
|
|
45
|
+
|
|
46
|
+
if(_nettle_FOUND)
|
|
47
|
+
set(Nettle_FOUND TRUE)
|
|
48
|
+
set(NETTLE_FOUND TRUE)
|
|
49
|
+
set(NETTLE_VERSION ${_nettle_VERSION})
|
|
50
|
+
message(STATUS "Found Nettle (via pkg-config): ${_nettle_INCLUDE_DIRS} (found version \"${NETTLE_VERSION}\")")
|
|
51
|
+
else()
|
|
52
|
+
find_path(NETTLE_INCLUDE_DIR NAMES "nettle/sha2.h")
|
|
53
|
+
find_library(NETTLE_LIBRARY NAMES "nettle")
|
|
54
|
+
|
|
55
|
+
unset(NETTLE_VERSION CACHE)
|
|
56
|
+
if(NETTLE_INCLUDE_DIR AND EXISTS "${NETTLE_INCLUDE_DIR}/nettle/version.h")
|
|
57
|
+
set(_version_regex1 "#[\t ]*define[ \t]+NETTLE_VERSION_MAJOR[ \t]+([0-9]+).*")
|
|
58
|
+
set(_version_regex2 "#[\t ]*define[ \t]+NETTLE_VERSION_MINOR[ \t]+([0-9]+).*")
|
|
59
|
+
file(STRINGS "${NETTLE_INCLUDE_DIR}/nettle/version.h" _version_str1 REGEX "${_version_regex1}")
|
|
60
|
+
file(STRINGS "${NETTLE_INCLUDE_DIR}/nettle/version.h" _version_str2 REGEX "${_version_regex2}")
|
|
61
|
+
string(REGEX REPLACE "${_version_regex1}" "\\1" _version_str1 "${_version_str1}")
|
|
62
|
+
string(REGEX REPLACE "${_version_regex2}" "\\1" _version_str2 "${_version_str2}")
|
|
63
|
+
set(NETTLE_VERSION "${_version_str1}.${_version_str2}")
|
|
64
|
+
unset(_version_regex1)
|
|
65
|
+
unset(_version_regex2)
|
|
66
|
+
unset(_version_str1)
|
|
67
|
+
unset(_version_str2)
|
|
68
|
+
endif()
|
|
69
|
+
|
|
70
|
+
include(FindPackageHandleStandardArgs)
|
|
71
|
+
find_package_handle_standard_args(Nettle
|
|
72
|
+
REQUIRED_VARS
|
|
73
|
+
NETTLE_INCLUDE_DIR
|
|
74
|
+
NETTLE_LIBRARY
|
|
75
|
+
VERSION_VAR
|
|
76
|
+
NETTLE_VERSION
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
if(NETTLE_FOUND)
|
|
80
|
+
set(_nettle_INCLUDE_DIRS ${NETTLE_INCLUDE_DIR})
|
|
81
|
+
set(_nettle_LIBRARIES ${NETTLE_LIBRARY})
|
|
82
|
+
endif()
|
|
83
|
+
|
|
84
|
+
mark_as_advanced(NETTLE_INCLUDE_DIR NETTLE_LIBRARY)
|
|
85
|
+
endif()
|
|
86
|
+
|
|
87
|
+
if(NETTLE_FOUND)
|
|
88
|
+
if(NOT TARGET CURL::nettle)
|
|
89
|
+
add_library(CURL::nettle INTERFACE IMPORTED)
|
|
90
|
+
set_target_properties(CURL::nettle PROPERTIES
|
|
91
|
+
INTERFACE_LIBCURL_PC_MODULES "${_nettle_pc_requires}"
|
|
92
|
+
INTERFACE_COMPILE_OPTIONS "${_nettle_CFLAGS}"
|
|
93
|
+
INTERFACE_INCLUDE_DIRECTORIES "${_nettle_INCLUDE_DIRS}"
|
|
94
|
+
INTERFACE_LINK_DIRECTORIES "${_nettle_LIBRARY_DIRS}"
|
|
95
|
+
INTERFACE_LINK_LIBRARIES "${_nettle_LIBRARIES}")
|
|
96
|
+
endif()
|
|
97
|
+
endif()
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
# Find the quiche library
|
|
25
|
+
#
|
|
26
|
+
# Input variables:
|
|
27
|
+
#
|
|
28
|
+
# - `QUICHE_INCLUDE_DIR`: Absolute path to quiche include directory.
|
|
29
|
+
# - `QUICHE_LIBRARY`: Absolute path to `quiche` library.
|
|
30
|
+
#
|
|
31
|
+
# Defines:
|
|
32
|
+
#
|
|
33
|
+
# - `QUICHE_FOUND`: System has quiche.
|
|
34
|
+
# - `QUICHE_VERSION`: Version of quiche.
|
|
35
|
+
# - `CURL::quiche`: quiche library target.
|
|
36
|
+
|
|
37
|
+
set(_quiche_pc_requires "quiche")
|
|
38
|
+
|
|
39
|
+
if(CURL_USE_PKGCONFIG AND
|
|
40
|
+
NOT DEFINED QUICHE_INCLUDE_DIR AND
|
|
41
|
+
NOT DEFINED QUICHE_LIBRARY)
|
|
42
|
+
find_package(PkgConfig QUIET)
|
|
43
|
+
pkg_check_modules(_quiche ${_quiche_pc_requires})
|
|
44
|
+
endif()
|
|
45
|
+
|
|
46
|
+
if(_quiche_FOUND)
|
|
47
|
+
set(Quiche_FOUND TRUE)
|
|
48
|
+
set(QUICHE_FOUND TRUE)
|
|
49
|
+
set(QUICHE_VERSION ${_quiche_VERSION})
|
|
50
|
+
message(STATUS "Found Quiche (via pkg-config): ${_quiche_INCLUDE_DIRS} (found version \"${QUICHE_VERSION}\")")
|
|
51
|
+
else()
|
|
52
|
+
find_path(QUICHE_INCLUDE_DIR NAMES "quiche.h")
|
|
53
|
+
find_library(QUICHE_LIBRARY NAMES "quiche")
|
|
54
|
+
|
|
55
|
+
include(FindPackageHandleStandardArgs)
|
|
56
|
+
find_package_handle_standard_args(Quiche
|
|
57
|
+
REQUIRED_VARS
|
|
58
|
+
QUICHE_INCLUDE_DIR
|
|
59
|
+
QUICHE_LIBRARY
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
if(QUICHE_FOUND)
|
|
63
|
+
set(_quiche_INCLUDE_DIRS ${QUICHE_INCLUDE_DIR})
|
|
64
|
+
set(_quiche_LIBRARIES ${QUICHE_LIBRARY})
|
|
65
|
+
endif()
|
|
66
|
+
|
|
67
|
+
mark_as_advanced(QUICHE_INCLUDE_DIR QUICHE_LIBRARY)
|
|
68
|
+
endif()
|
|
69
|
+
|
|
70
|
+
if(QUICHE_FOUND)
|
|
71
|
+
if(NOT TARGET CURL::quiche)
|
|
72
|
+
add_library(CURL::quiche INTERFACE IMPORTED)
|
|
73
|
+
set_target_properties(CURL::quiche PROPERTIES
|
|
74
|
+
INTERFACE_LIBCURL_PC_MODULES "${_quiche_pc_requires}"
|
|
75
|
+
INTERFACE_COMPILE_OPTIONS "${_quiche_CFLAGS}"
|
|
76
|
+
INTERFACE_INCLUDE_DIRECTORIES "${_quiche_INCLUDE_DIRS}"
|
|
77
|
+
INTERFACE_LINK_DIRECTORIES "${_quiche_LIBRARY_DIRS}"
|
|
78
|
+
INTERFACE_LINK_LIBRARIES "${_quiche_LIBRARIES}")
|
|
79
|
+
endif()
|
|
80
|
+
endif()
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
# Find the Rustls library
|
|
25
|
+
#
|
|
26
|
+
# Input variables:
|
|
27
|
+
#
|
|
28
|
+
# - `RUSTLS_INCLUDE_DIR`: Absolute path to Rustls include directory.
|
|
29
|
+
# - `RUSTLS_LIBRARY`: Absolute path to `rustls` library.
|
|
30
|
+
#
|
|
31
|
+
# Defines:
|
|
32
|
+
#
|
|
33
|
+
# - `RUSTLS_FOUND`: System has Rustls.
|
|
34
|
+
# - `RUSTLS_VERSION`: Version of Rustls.
|
|
35
|
+
# - `CURL::rustls`: Rustls library target.
|
|
36
|
+
|
|
37
|
+
set(_rustls_pc_requires "rustls")
|
|
38
|
+
|
|
39
|
+
if(CURL_USE_PKGCONFIG AND
|
|
40
|
+
NOT DEFINED RUSTLS_INCLUDE_DIR AND
|
|
41
|
+
NOT DEFINED RUSTLS_LIBRARY)
|
|
42
|
+
find_package(PkgConfig QUIET)
|
|
43
|
+
pkg_check_modules(_rustls ${_rustls_pc_requires})
|
|
44
|
+
endif()
|
|
45
|
+
|
|
46
|
+
if(_rustls_FOUND)
|
|
47
|
+
set(Rustls_FOUND TRUE)
|
|
48
|
+
set(RUSTLS_FOUND TRUE)
|
|
49
|
+
set(RUSTLS_VERSION ${_rustls_VERSION})
|
|
50
|
+
message(STATUS "Found Rustls (via pkg-config): ${_rustls_INCLUDE_DIRS} (found version \"${RUSTLS_VERSION}\")")
|
|
51
|
+
else()
|
|
52
|
+
set(_rustls_pc_requires "") # Depend on pkg-config only when found via pkg-config
|
|
53
|
+
|
|
54
|
+
find_path(RUSTLS_INCLUDE_DIR NAMES "rustls.h")
|
|
55
|
+
find_library(RUSTLS_LIBRARY NAMES "rustls")
|
|
56
|
+
|
|
57
|
+
include(FindPackageHandleStandardArgs)
|
|
58
|
+
find_package_handle_standard_args(Rustls
|
|
59
|
+
REQUIRED_VARS
|
|
60
|
+
RUSTLS_INCLUDE_DIR
|
|
61
|
+
RUSTLS_LIBRARY
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
if(RUSTLS_FOUND)
|
|
65
|
+
set(_rustls_INCLUDE_DIRS ${RUSTLS_INCLUDE_DIR})
|
|
66
|
+
set(_rustls_LIBRARIES ${RUSTLS_LIBRARY})
|
|
67
|
+
endif()
|
|
68
|
+
|
|
69
|
+
mark_as_advanced(RUSTLS_INCLUDE_DIR RUSTLS_LIBRARY)
|
|
70
|
+
endif()
|
|
71
|
+
|
|
72
|
+
if(RUSTLS_FOUND)
|
|
73
|
+
if(APPLE)
|
|
74
|
+
find_library(SECURITY_FRAMEWORK NAMES "Security")
|
|
75
|
+
mark_as_advanced(SECURITY_FRAMEWORK)
|
|
76
|
+
if(NOT SECURITY_FRAMEWORK)
|
|
77
|
+
message(FATAL_ERROR "Security framework not found")
|
|
78
|
+
endif()
|
|
79
|
+
list(APPEND _rustls_LIBRARIES "-framework Security")
|
|
80
|
+
|
|
81
|
+
find_library(FOUNDATION_FRAMEWORK NAMES "Foundation")
|
|
82
|
+
mark_as_advanced(FOUNDATION_FRAMEWORK)
|
|
83
|
+
if(NOT FOUNDATION_FRAMEWORK)
|
|
84
|
+
message(FATAL_ERROR "Foundation framework not found")
|
|
85
|
+
endif()
|
|
86
|
+
list(APPEND _rustls_LIBRARIES "-framework Foundation")
|
|
87
|
+
elseif(NOT WIN32)
|
|
88
|
+
find_library(PTHREAD_LIBRARY NAMES "pthread")
|
|
89
|
+
if(PTHREAD_LIBRARY)
|
|
90
|
+
list(APPEND _rustls_LIBRARIES ${PTHREAD_LIBRARY})
|
|
91
|
+
endif()
|
|
92
|
+
mark_as_advanced(PTHREAD_LIBRARY)
|
|
93
|
+
|
|
94
|
+
find_library(DL_LIBRARY NAMES "dl")
|
|
95
|
+
if(DL_LIBRARY)
|
|
96
|
+
list(APPEND _rustls_LIBRARIES ${DL_LIBRARY})
|
|
97
|
+
endif()
|
|
98
|
+
mark_as_advanced(DL_LIBRARY)
|
|
99
|
+
|
|
100
|
+
find_library(MATH_LIBRARY NAMES "m")
|
|
101
|
+
if(MATH_LIBRARY)
|
|
102
|
+
list(APPEND _rustls_LIBRARIES ${MATH_LIBRARY})
|
|
103
|
+
endif()
|
|
104
|
+
mark_as_advanced(MATH_LIBRARY)
|
|
105
|
+
endif()
|
|
106
|
+
|
|
107
|
+
if(NOT TARGET CURL::rustls)
|
|
108
|
+
add_library(CURL::rustls INTERFACE IMPORTED)
|
|
109
|
+
set_target_properties(CURL::rustls PROPERTIES
|
|
110
|
+
INTERFACE_LIBCURL_PC_MODULES "${_rustls_pc_requires}"
|
|
111
|
+
INTERFACE_COMPILE_OPTIONS "${_rustls_CFLAGS}"
|
|
112
|
+
INTERFACE_INCLUDE_DIRECTORIES "${_rustls_INCLUDE_DIRS}"
|
|
113
|
+
INTERFACE_LINK_DIRECTORIES "${_rustls_LIBRARY_DIRS}"
|
|
114
|
+
INTERFACE_LINK_LIBRARIES "${_rustls_LIBRARIES}")
|
|
115
|
+
endif()
|
|
116
|
+
endif()
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
# Find the wolfSSL library
|
|
25
|
+
#
|
|
26
|
+
# Input variables:
|
|
27
|
+
#
|
|
28
|
+
# - `WOLFSSL_INCLUDE_DIR`: Absolute path to wolfSSL include directory.
|
|
29
|
+
# - `WOLFSSL_LIBRARY`: Absolute path to `wolfssl` library.
|
|
30
|
+
#
|
|
31
|
+
# Defines:
|
|
32
|
+
#
|
|
33
|
+
# - `WOLFSSL_FOUND`: System has wolfSSL.
|
|
34
|
+
# - `WOLFSSL_VERSION`: Version of wolfSSL.
|
|
35
|
+
# - `CURL::wolfssl`: wolfSSL library target.
|
|
36
|
+
|
|
37
|
+
if(DEFINED WolfSSL_INCLUDE_DIR AND NOT DEFINED WOLFSSL_INCLUDE_DIR)
|
|
38
|
+
message(WARNING "WolfSSL_INCLUDE_DIR is deprecated, use WOLFSSL_INCLUDE_DIR instead.")
|
|
39
|
+
set(WOLFSSL_INCLUDE_DIR "${WolfSSL_INCLUDE_DIR}")
|
|
40
|
+
endif()
|
|
41
|
+
if(DEFINED WolfSSL_LIBRARY AND NOT DEFINED WOLFSSL_LIBRARY)
|
|
42
|
+
message(WARNING "WolfSSL_LIBRARY is deprecated, use WOLFSSL_LIBRARY instead.")
|
|
43
|
+
set(WOLFSSL_LIBRARY "${WolfSSL_LIBRARY}")
|
|
44
|
+
endif()
|
|
45
|
+
|
|
46
|
+
set(_wolfssl_pc_requires "wolfssl")
|
|
47
|
+
|
|
48
|
+
if(NOT DEFINED WOLFSSL_INCLUDE_DIR AND
|
|
49
|
+
NOT DEFINED WOLFSSL_LIBRARY)
|
|
50
|
+
if(CURL_USE_PKGCONFIG)
|
|
51
|
+
find_package(PkgConfig QUIET)
|
|
52
|
+
pkg_check_modules(_wolfssl ${_wolfssl_pc_requires})
|
|
53
|
+
endif()
|
|
54
|
+
if(NOT _wolfssl_FOUND AND CURL_USE_CMAKECONFIG)
|
|
55
|
+
find_package(wolfssl CONFIG QUIET)
|
|
56
|
+
endif()
|
|
57
|
+
endif()
|
|
58
|
+
|
|
59
|
+
if(_wolfssl_FOUND)
|
|
60
|
+
set(WolfSSL_FOUND TRUE)
|
|
61
|
+
set(WOLFSSL_FOUND TRUE)
|
|
62
|
+
set(WOLFSSL_VERSION ${_wolfssl_VERSION})
|
|
63
|
+
message(STATUS "Found WolfSSL (via pkg-config): ${_wolfssl_INCLUDE_DIRS} (found version \"${WOLFSSL_VERSION}\")")
|
|
64
|
+
elseif(wolfssl_CONFIG)
|
|
65
|
+
set(WolfSSL_FOUND TRUE)
|
|
66
|
+
set(WOLFSSL_FOUND TRUE)
|
|
67
|
+
set(WOLFSSL_VERSION ${wolfssl_VERSION})
|
|
68
|
+
set(_wolfssl_LIBRARIES wolfssl::wolfssl)
|
|
69
|
+
message(STATUS "Found WolfSSL (via CMake Config): ${wolfssl_CONFIG} (found version \"${WOLFSSL_VERSION}\")")
|
|
70
|
+
else()
|
|
71
|
+
find_path(WOLFSSL_INCLUDE_DIR NAMES "wolfssl/ssl.h")
|
|
72
|
+
find_library(WOLFSSL_LIBRARY NAMES "wolfssl")
|
|
73
|
+
|
|
74
|
+
unset(WOLFSSL_VERSION CACHE)
|
|
75
|
+
if(WOLFSSL_INCLUDE_DIR AND EXISTS "${WOLFSSL_INCLUDE_DIR}/wolfssl/version.h")
|
|
76
|
+
set(_version_regex "#[\t ]*define[\t ]+LIBWOLFSSL_VERSION_STRING[\t ]+\"([^\"]*)\"")
|
|
77
|
+
file(STRINGS "${WOLFSSL_INCLUDE_DIR}/wolfssl/version.h" _version_str REGEX "${_version_regex}")
|
|
78
|
+
string(REGEX REPLACE "${_version_regex}" "\\1" _version_str "${_version_str}")
|
|
79
|
+
set(WOLFSSL_VERSION "${_version_str}")
|
|
80
|
+
unset(_version_regex)
|
|
81
|
+
unset(_version_str)
|
|
82
|
+
endif()
|
|
83
|
+
|
|
84
|
+
include(FindPackageHandleStandardArgs)
|
|
85
|
+
find_package_handle_standard_args(WolfSSL
|
|
86
|
+
REQUIRED_VARS
|
|
87
|
+
WOLFSSL_INCLUDE_DIR
|
|
88
|
+
WOLFSSL_LIBRARY
|
|
89
|
+
VERSION_VAR
|
|
90
|
+
WOLFSSL_VERSION
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
if(WOLFSSL_FOUND)
|
|
94
|
+
set(_wolfssl_INCLUDE_DIRS ${WOLFSSL_INCLUDE_DIR})
|
|
95
|
+
set(_wolfssl_LIBRARIES ${WOLFSSL_LIBRARY})
|
|
96
|
+
endif()
|
|
97
|
+
|
|
98
|
+
mark_as_advanced(WOLFSSL_INCLUDE_DIR WOLFSSL_LIBRARY)
|
|
99
|
+
endif()
|
|
100
|
+
|
|
101
|
+
if(WOLFSSL_FOUND)
|
|
102
|
+
if(APPLE)
|
|
103
|
+
find_library(SECURITY_FRAMEWORK NAMES "Security")
|
|
104
|
+
mark_as_advanced(SECURITY_FRAMEWORK)
|
|
105
|
+
if(NOT SECURITY_FRAMEWORK)
|
|
106
|
+
message(FATAL_ERROR "Security framework not found")
|
|
107
|
+
endif()
|
|
108
|
+
list(APPEND _wolfssl_LIBRARIES "-framework Security")
|
|
109
|
+
|
|
110
|
+
find_library(COREFOUNDATION_FRAMEWORK NAMES "CoreFoundation")
|
|
111
|
+
mark_as_advanced(COREFOUNDATION_FRAMEWORK)
|
|
112
|
+
if(NOT COREFOUNDATION_FRAMEWORK)
|
|
113
|
+
message(FATAL_ERROR "CoreFoundation framework not found")
|
|
114
|
+
endif()
|
|
115
|
+
list(APPEND _wolfssl_LIBRARIES "-framework CoreFoundation")
|
|
116
|
+
elseif(WIN32)
|
|
117
|
+
list(APPEND _wolfssl_LIBRARIES "crypt32")
|
|
118
|
+
else()
|
|
119
|
+
find_library(MATH_LIBRARY NAMES "m")
|
|
120
|
+
if(MATH_LIBRARY)
|
|
121
|
+
list(APPEND _wolfssl_LIBRARIES ${MATH_LIBRARY}) # for log and pow
|
|
122
|
+
endif()
|
|
123
|
+
mark_as_advanced(MATH_LIBRARY)
|
|
124
|
+
endif()
|
|
125
|
+
|
|
126
|
+
if(NOT TARGET CURL::wolfssl)
|
|
127
|
+
add_library(CURL::wolfssl INTERFACE IMPORTED)
|
|
128
|
+
set_target_properties(CURL::wolfssl PROPERTIES
|
|
129
|
+
INTERFACE_LIBCURL_PC_MODULES "${_wolfssl_pc_requires}"
|
|
130
|
+
INTERFACE_COMPILE_OPTIONS "${_wolfssl_CFLAGS}"
|
|
131
|
+
INTERFACE_INCLUDE_DIRECTORIES "${_wolfssl_INCLUDE_DIRS}"
|
|
132
|
+
INTERFACE_LINK_DIRECTORIES "${_wolfssl_LIBRARY_DIRS}"
|
|
133
|
+
INTERFACE_LINK_LIBRARIES "${_wolfssl_LIBRARIES}")
|
|
134
|
+
endif()
|
|
135
|
+
endif()
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
# Find the zstd library
|
|
25
|
+
#
|
|
26
|
+
# Input variables:
|
|
27
|
+
#
|
|
28
|
+
# - `ZSTD_INCLUDE_DIR`: Absolute path to zstd include directory.
|
|
29
|
+
# - `ZSTD_LIBRARY`: Absolute path to `zstd` library.
|
|
30
|
+
# - `ZSTD_USE_STATIC_LIBS`: Configure for static zstd libraries.
|
|
31
|
+
#
|
|
32
|
+
# Defines:
|
|
33
|
+
#
|
|
34
|
+
# - `ZSTD_FOUND`: System has zstd.
|
|
35
|
+
# - `ZSTD_VERSION`: Version of zstd.
|
|
36
|
+
# - `CURL::zstd`: zstd library target.
|
|
37
|
+
|
|
38
|
+
if(DEFINED Zstd_INCLUDE_DIR AND NOT DEFINED ZSTD_INCLUDE_DIR)
|
|
39
|
+
message(WARNING "Zstd_INCLUDE_DIR is deprecated, use ZSTD_INCLUDE_DIR instead.")
|
|
40
|
+
set(ZSTD_INCLUDE_DIR "${Zstd_INCLUDE_DIR}")
|
|
41
|
+
endif()
|
|
42
|
+
if(DEFINED Zstd_LIBRARY AND NOT DEFINED ZSTD_LIBRARY)
|
|
43
|
+
message(WARNING "Zstd_LIBRARY is deprecated, use ZSTD_LIBRARY instead.")
|
|
44
|
+
set(ZSTD_LIBRARY "${Zstd_LIBRARY}")
|
|
45
|
+
endif()
|
|
46
|
+
|
|
47
|
+
set(_zstd_pc_requires "libzstd")
|
|
48
|
+
|
|
49
|
+
if(NOT DEFINED ZSTD_INCLUDE_DIR AND
|
|
50
|
+
NOT DEFINED ZSTD_LIBRARY)
|
|
51
|
+
if(CURL_USE_PKGCONFIG)
|
|
52
|
+
find_package(PkgConfig QUIET)
|
|
53
|
+
pkg_check_modules(_zstd ${_zstd_pc_requires})
|
|
54
|
+
endif()
|
|
55
|
+
if(NOT _zstd_FOUND AND CURL_USE_CMAKECONFIG)
|
|
56
|
+
find_package(zstd CONFIG QUIET)
|
|
57
|
+
# Skip using if older than v1.4.5
|
|
58
|
+
if(zstd_CONFIG AND
|
|
59
|
+
NOT TARGET zstd::libzstd_static AND
|
|
60
|
+
NOT TARGET zstd::libzstd_shared)
|
|
61
|
+
unset(zstd_CONFIG)
|
|
62
|
+
endif()
|
|
63
|
+
endif()
|
|
64
|
+
endif()
|
|
65
|
+
|
|
66
|
+
if(_zstd_FOUND)
|
|
67
|
+
set(Zstd_FOUND TRUE)
|
|
68
|
+
set(ZSTD_FOUND TRUE)
|
|
69
|
+
set(ZSTD_VERSION ${_zstd_VERSION})
|
|
70
|
+
if(ZSTD_USE_STATIC_LIBS)
|
|
71
|
+
set(_zstd_CFLAGS "${_zstd_STATIC_CFLAGS}")
|
|
72
|
+
set(_zstd_INCLUDE_DIRS "${_zstd_STATIC_INCLUDE_DIRS}")
|
|
73
|
+
set(_zstd_LIBRARY_DIRS "${_zstd_STATIC_LIBRARY_DIRS}")
|
|
74
|
+
set(_zstd_LIBRARIES "${_zstd_STATIC_LIBRARIES}")
|
|
75
|
+
endif()
|
|
76
|
+
message(STATUS "Found Zstd (via pkg-config): ${_zstd_INCLUDE_DIRS} (found version \"${ZSTD_VERSION}\")")
|
|
77
|
+
elseif(zstd_CONFIG)
|
|
78
|
+
set(Zstd_FOUND TRUE)
|
|
79
|
+
set(ZSTD_FOUND TRUE)
|
|
80
|
+
set(ZSTD_VERSION ${zstd_VERSION})
|
|
81
|
+
if(ZSTD_USE_STATIC_LIBS)
|
|
82
|
+
set(_zstd_LIBRARIES zstd::libzstd_static)
|
|
83
|
+
elseif(TARGET zstd::libzstd)
|
|
84
|
+
set(_zstd_LIBRARIES zstd::libzstd) # v1.5.6+
|
|
85
|
+
else()
|
|
86
|
+
set(_zstd_LIBRARIES zstd::libzstd_shared)
|
|
87
|
+
endif()
|
|
88
|
+
message(STATUS "Found Zstd (via CMake Config): ${zstd_CONFIG} (found version \"${ZSTD_VERSION}\")")
|
|
89
|
+
else()
|
|
90
|
+
find_path(ZSTD_INCLUDE_DIR NAMES "zstd.h")
|
|
91
|
+
if(ZSTD_USE_STATIC_LIBS)
|
|
92
|
+
find_library(ZSTD_LIBRARY NAMES "zstd_static" "zstd")
|
|
93
|
+
else()
|
|
94
|
+
find_library(ZSTD_LIBRARY NAMES "zstd")
|
|
95
|
+
endif()
|
|
96
|
+
|
|
97
|
+
unset(ZSTD_VERSION CACHE)
|
|
98
|
+
if(ZSTD_INCLUDE_DIR AND EXISTS "${ZSTD_INCLUDE_DIR}/zstd.h")
|
|
99
|
+
set(_version_regex1 "#[\t ]*define[ \t]+ZSTD_VERSION_MAJOR[ \t]+([0-9]+).*")
|
|
100
|
+
set(_version_regex2 "#[\t ]*define[ \t]+ZSTD_VERSION_MINOR[ \t]+([0-9]+).*")
|
|
101
|
+
set(_version_regex3 "#[\t ]*define[ \t]+ZSTD_VERSION_RELEASE[ \t]+([0-9]+).*")
|
|
102
|
+
file(STRINGS "${ZSTD_INCLUDE_DIR}/zstd.h" _version_str1 REGEX "${_version_regex1}")
|
|
103
|
+
file(STRINGS "${ZSTD_INCLUDE_DIR}/zstd.h" _version_str2 REGEX "${_version_regex2}")
|
|
104
|
+
file(STRINGS "${ZSTD_INCLUDE_DIR}/zstd.h" _version_str3 REGEX "${_version_regex3}")
|
|
105
|
+
string(REGEX REPLACE "${_version_regex1}" "\\1" _version_str1 "${_version_str1}")
|
|
106
|
+
string(REGEX REPLACE "${_version_regex2}" "\\1" _version_str2 "${_version_str2}")
|
|
107
|
+
string(REGEX REPLACE "${_version_regex3}" "\\1" _version_str3 "${_version_str3}")
|
|
108
|
+
set(ZSTD_VERSION "${_version_str1}.${_version_str2}.${_version_str3}")
|
|
109
|
+
unset(_version_regex1)
|
|
110
|
+
unset(_version_regex2)
|
|
111
|
+
unset(_version_regex3)
|
|
112
|
+
unset(_version_str1)
|
|
113
|
+
unset(_version_str2)
|
|
114
|
+
unset(_version_str3)
|
|
115
|
+
endif()
|
|
116
|
+
|
|
117
|
+
include(FindPackageHandleStandardArgs)
|
|
118
|
+
find_package_handle_standard_args(Zstd
|
|
119
|
+
REQUIRED_VARS
|
|
120
|
+
ZSTD_INCLUDE_DIR
|
|
121
|
+
ZSTD_LIBRARY
|
|
122
|
+
VERSION_VAR
|
|
123
|
+
ZSTD_VERSION
|
|
124
|
+
)
|
|
125
|
+
|
|
126
|
+
if(ZSTD_FOUND)
|
|
127
|
+
set(_zstd_INCLUDE_DIRS ${ZSTD_INCLUDE_DIR})
|
|
128
|
+
set(_zstd_LIBRARIES ${ZSTD_LIBRARY})
|
|
129
|
+
endif()
|
|
130
|
+
|
|
131
|
+
mark_as_advanced(ZSTD_INCLUDE_DIR ZSTD_LIBRARY)
|
|
132
|
+
endif()
|
|
133
|
+
|
|
134
|
+
if(ZSTD_FOUND)
|
|
135
|
+
if(NOT TARGET CURL::zstd)
|
|
136
|
+
add_library(CURL::zstd INTERFACE IMPORTED)
|
|
137
|
+
set_target_properties(CURL::zstd PROPERTIES
|
|
138
|
+
INTERFACE_LIBCURL_PC_MODULES "${_zstd_pc_requires}"
|
|
139
|
+
INTERFACE_COMPILE_OPTIONS "${_zstd_CFLAGS}"
|
|
140
|
+
INTERFACE_INCLUDE_DIRECTORIES "${_zstd_INCLUDE_DIRS}"
|
|
141
|
+
INTERFACE_LINK_DIRECTORIES "${_zstd_LIBRARY_DIRS}"
|
|
142
|
+
INTERFACE_LINK_LIBRARIES "${_zstd_LIBRARIES}")
|
|
143
|
+
endif()
|
|
144
|
+
endif()
|
|
Binary file
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
#***************************************************************************
|
|
2
|
+
# _ _ ____ _
|
|
3
|
+
# Project ___| | | | _ \| |
|
|
4
|
+
# / __| | | | |_) | |
|
|
5
|
+
# | (__| |_| | _ <| |___
|
|
6
|
+
# \___|\___/|_| \_\_____|
|
|
7
|
+
#
|
|
8
|
+
# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
|
9
|
+
#
|
|
10
|
+
# This software is licensed as described in the file COPYING, which
|
|
11
|
+
# you should have received as part of this distribution. The terms
|
|
12
|
+
# are also available at https://curl.se/docs/copyright.html.
|
|
13
|
+
#
|
|
14
|
+
# You may opt to use, copy, modify, merge, publish, distribute and/or sell
|
|
15
|
+
# copies of the Software, and permit persons to whom the Software is
|
|
16
|
+
# furnished to do so, under the terms of the COPYING file.
|
|
17
|
+
#
|
|
18
|
+
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
19
|
+
# KIND, either express or implied.
|
|
20
|
+
#
|
|
21
|
+
# SPDX-License-Identifier: curl
|
|
22
|
+
#
|
|
23
|
+
###########################################################################
|
|
24
|
+
|
|
25
|
+
prefix=/Users/bugra/Documents/cpp.js/ports/curl/ios/.crossbind/build/Source-Release/prebuilt/ios-iphonesimulator-mt-release
|
|
26
|
+
exec_prefix=${prefix}
|
|
27
|
+
libdir=${exec_prefix}/lib
|
|
28
|
+
includedir=${prefix}/include
|
|
29
|
+
supported_protocols="DICT FILE FTP FTPS GOPHER GOPHERS HTTP HTTPS IMAP IMAPS IPFS IPNS MQTT MQTTS POP3 POP3S RTSP SMTP SMTPS TELNET TFTP WS WSS"
|
|
30
|
+
supported_features="alt-svc AsynchDNS HSTS HTTPS-proxy Largefile libz SSL threadsafe TLS-SRP UnixSockets"
|
|
31
|
+
|
|
32
|
+
Name: libcurl
|
|
33
|
+
URL: https://curl.se/
|
|
34
|
+
Description: Library to transfer files with HTTP, FTP, etc.
|
|
35
|
+
Version: 8.21.0
|
|
36
|
+
Requires: openssl,zlib
|
|
37
|
+
Requires.private: openssl,zlib
|
|
38
|
+
Libs: -L${libdir} -lcurl -lssl -lcrypto -lz
|
|
39
|
+
Libs.private: -lssl -lcrypto -lz
|
|
40
|
+
Cflags: -I${includedir} -DCURL_STATICLIB
|
|
41
|
+
Cflags.private: -DCURL_STATICLIB
|