Create JIT as a feature (#31294)

This commit is contained in:
talregev 2023-05-11 21:37:21 +03:00 committed by GitHub
parent 9411949cbc
commit d54600af13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 35 additions and 8 deletions

View File

@ -13,20 +13,21 @@ string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" BUILD_STATIC)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" INSTALL_PDB)
string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" BUILD_STATIC_CRT)
set(JIT ON)
if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "Emscripten" OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "iOS")
set(JIT OFF)
endif()
vcpkg_check_features(
OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
jit PCRE2_SUPPORT_JIT
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
${FEATURE_OPTIONS}
-DBUILD_STATIC_LIBS=${BUILD_STATIC}
-DPCRE2_STATIC_RUNTIME=${BUILD_STATIC_CRT}
-DPCRE2_BUILD_PCRE2_8=ON
-DPCRE2_BUILD_PCRE2_16=ON
-DPCRE2_BUILD_PCRE2_32=ON
-DPCRE2_SUPPORT_JIT=${JIT}
-DPCRE2_SUPPORT_UNICODE=ON
-DPCRE2_BUILD_TESTS=OFF
-DPCRE2_BUILD_PCRE2GREP=OFF

View File

@ -1,7 +1,7 @@
{
"name": "pcre2",
"version": "10.40",
"port-version": 1,
"port-version": 2,
"description": "Regular Expression pattern matching using the same syntax and semantics as Perl 5.",
"homepage": "https://github.com/PCRE2Project/pcre2",
"license": "BSD-3-Clause",
@ -19,5 +19,26 @@
"host": true
},
"zlib"
]
],
"default-features": [
"platform-default-features"
],
"features": {
"jit": {
"description": "Build JIT support",
"supports": "!emscripten"
},
"platform-default-features": {
"description": "Enable default features",
"dependencies": [
{
"name": "pcre2",
"features": [
"jit"
],
"platform": "!emscripten"
}
]
}
}
}

View File

@ -6110,7 +6110,7 @@
},
"pcre2": {
"baseline": "10.40",
"port-version": 1
"port-version": 2
},
"pdal": {
"baseline": "2.5.3",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "533fc8ada3da33f695eb499fe8190a5e9b24a5c8",
"version": "10.40",
"port-version": 2
},
{
"git-tree": "941f187c16a9385815fd353a9b79abf55bd2a7ec",
"version": "10.40",