From nobody Mon Aug 21 19:05:18 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RV23y6DD8z4rC3d; Mon, 21 Aug 2023 19:05:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RV23y60F8z4Mmt; Mon, 21 Aug 2023 19:05:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692644718; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GeLbiLWiyRnYCImnQWmZ6El77O8XdpwAlyyIvLEQnmg=; b=htP3oOXfRcv6/NygDCErgdgPw0bkL4VhnlEGLAFIkK+l9aLqN1pwVWebD02i6l9pWGYmei 5EHYpnBkmt1uEpoCO0ruwsVAXPxivnYOXI93Y/bM7YQGbDlGj/2At28EXM2HQCo44Kz0sq 2xgYWwLPIY6rAdMMxwMy2Et1LxhW1i5cZecNmjvr61Chk0N4zqCbg0+TebSWk9DobmD+AZ OLjdC+Ed5nAtfB0scY4Ohq5Ym9DhKaPS3NclfNN/s60NJvSXHUdEUKXRjiDlRXMP1xj55Q zfwcPW0rOojat/JCzzvoG8l2hQeFufBDKC4erYkw/6X4nES4SztPiEZpdH11Rw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692644718; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GeLbiLWiyRnYCImnQWmZ6El77O8XdpwAlyyIvLEQnmg=; b=pNblYDp9RtSynaymdrVYb7XR9V8tm9WK8v38wcypR2xQjI81IMF74LIARUMA7LmGgroY8l RkK+aYBQU3BwzLgj8C0M9vu/cJ0uWKiTIOgiKkcSbcuiYn/fW54i14RBm4JN2s0ZE/Biwi bPncbmG980Co8Z9lQMXllPRPVEXq0FKeYWN9/Jv2BuUmnqPI6QPvaSOCj+X+YMlhxbxhpD cpzobcHOQdOG8wS5rs2odiNIFKa7oX8JY0VcrLE7GcwTo2NhDgBrW9hqJ65eIvI0jQl3f+ Nl1vFW7oaYluv1+xssXQrlVjd5mi4d5N2ZApdJQhEzZy2NzehSxMB9v0a1aTnw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1692644718; a=rsa-sha256; cv=none; b=n678GpD79eMwgdZDRBnlp5CwReNGOIOcPymDywXs5r3fIlfgGEdIhVB8kxzRbihK/xr/Qe 5fXFYECwBjOkms3mXmyzM2RNjFfWbQ8R+77rdif2bzS9dqvVN8XvyuyedqjOm9jei6+/H3 1U6WW7z6LifG/KCdbbGhnZQ9t+UPZIEuyIgU5WVsv7gI+D6r6jpk9r7h37m2o3rgHxg5yX MP2zUoa6th0Mn1Xsb7f3bYT3k1owuwHifZ5fnBfOMa00+/7zxx+VbgD4sSZtp2Bl9oiZR7 EyzA+wpKp7VRBsKTLeHAILbEgtVI74vdb0z06Yr74RKQDM3QGBrAg4O6zWSklg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RV23y4tn4zXSl; Mon, 21 Aug 2023 19:05:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 37LJ5Ieh096139; Mon, 21 Aug 2023 19:05:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 37LJ5IA6096136; Mon, 21 Aug 2023 19:05:18 GMT (envelope-from git) Date: Mon, 21 Aug 2023 19:05:18 GMT Message-Id: <202308211905.37LJ5IA6096136@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: 7763ad8dc10a - main - devel/libddwaf: Update to 1.13.0 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7763ad8dc10aad06b262cbe4d3c0c63dcae42135 Auto-Submitted: auto-generated The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=7763ad8dc10aad06b262cbe4d3c0c63dcae42135 commit 7763ad8dc10aad06b262cbe4d3c0c63dcae42135 Author: Po-Chuan Hsieh AuthorDate: 2023-08-21 18:52:01 +0000 Commit: Po-Chuan Hsieh CommitDate: 2023-08-21 18:52:01 +0000 devel/libddwaf: Update to 1.13.0 Changes: https://github.com/DataDog/libddwaf/releases --- devel/libddwaf/Makefile | 4 +- devel/libddwaf/distinfo | 10 +- devel/libddwaf/files/patch-CMakeLists.txt | 48 +++++---- .../files/patch-third_party-CMakeLists.txt | 109 +++++++++++---------- 4 files changed, 95 insertions(+), 76 deletions(-) diff --git a/devel/libddwaf/Makefile b/devel/libddwaf/Makefile index 447d0330c3f6..8e3a717470aa 100644 --- a/devel/libddwaf/Makefile +++ b/devel/libddwaf/Makefile @@ -1,5 +1,5 @@ PORTNAME= libddwaf -PORTVERSION= 1.12.0 +PORTVERSION= 1.13.0 CATEGORIES= devel MAINTAINER= sunpoet@FreeBSD.org @@ -28,7 +28,7 @@ CMAKE_ON= LIBDDWAF_BUILD_SHARED LIBDDWAF_BUILD_STATIC USE_GITHUB= yes GH_ACCOUNT= DataDog GH_TUPLE= DataDog:appsec-event-rules:1.7.1:DataDog_appsec_event_rules/third_party/proj_event_rules \ - Tencent:rapidjson:a95e013:Tencent_rapidjson/third_party/rapidjson + Tencent:rapidjson:476ffa2:Tencent_rapidjson/third_party/rapidjson post-patch: # Clean up bundled libraries diff --git a/devel/libddwaf/distinfo b/devel/libddwaf/distinfo index 2251211e6500..8ff8da89b863 100644 --- a/devel/libddwaf/distinfo +++ b/devel/libddwaf/distinfo @@ -1,7 +1,7 @@ -TIMESTAMP = 1691069924 -SHA256 (DataDog-libddwaf-1.12.0_GH0.tar.gz) = 68000b76f44118fe726750df3a54effc987def5b368be002c495383df9437ac4 -SIZE (DataDog-libddwaf-1.12.0_GH0.tar.gz) = 745164 +TIMESTAMP = 1692640036 +SHA256 (DataDog-libddwaf-1.13.0_GH0.tar.gz) = f473559fb5a78c3bbd760dc963c2b2c089e614c3e3b6723934ab5ce2d4c59cee +SIZE (DataDog-libddwaf-1.13.0_GH0.tar.gz) = 767017 SHA256 (DataDog-appsec-event-rules-1.7.1_GH0.tar.gz) = df0e72ec448f66f7752c0f6c411b8172751524eaae66b9219a477668e1e65f91 SIZE (DataDog-appsec-event-rules-1.7.1_GH0.tar.gz) = 134403 -SHA256 (Tencent-rapidjson-a95e013_GH0.tar.gz) = 44d777549051b4dabea4dd2290d6b63a340c103e819da0c85f658606f4e88b6a -SIZE (Tencent-rapidjson-a95e013_GH0.tar.gz) = 1115459 +SHA256 (Tencent-rapidjson-476ffa2_GH0.tar.gz) = 6a1628b73d007ffe5d2bc84f206d05b2194e25eeb0585a41bfd29db150591f84 +SIZE (Tencent-rapidjson-476ffa2_GH0.tar.gz) = 1115582 diff --git a/devel/libddwaf/files/patch-CMakeLists.txt b/devel/libddwaf/files/patch-CMakeLists.txt index 7409c74399cc..5d7df8ac29b0 100644 --- a/devel/libddwaf/files/patch-CMakeLists.txt +++ b/devel/libddwaf/files/patch-CMakeLists.txt @@ -1,13 +1,15 @@ ---- CMakeLists.txt.orig 2023-07-28 08:52:50 UTC +--- CMakeLists.txt.orig 2023-08-17 10:28:49 UTC +++ CMakeLists.txt -@@ -8,23 +8,23 @@ set(CMAKE_PROJECT_VERSION ${version}) +@@ -7,24 +7,24 @@ set(CMAKE_PROJECT_VERSION ${version}) + configure_file(src/version.hpp.in ${CMAKE_CURRENT_SOURCE_DIR}/src/version.hpp) - set(CMAKE_OSX_DEPLOYMENT_TARGET "10.12" CACHE STRING "Minimum OS X deployment version") +-set(CMAKE_OSX_DEPLOYMENT_TARGET "10.12" CACHE STRING "Minimum OS X deployment version") -if(CMAKE_OSX_ARCHITECTURES MATCHES "x86_64" OR - CMAKE_OSX_ARCHITECTURES MATCHES "arm64") - set(CPU_TYPE ${CMAKE_OSX_ARCHITECTURES}) -endif() ++#set(CMAKE_OSX_DEPLOYMENT_TARGET "10.12" CACHE STRING "Minimum OS X deployment version") +#if(CMAKE_OSX_ARCHITECTURES MATCHES "x86_64" OR +# CMAKE_OSX_ARCHITECTURES MATCHES "arm64") +# set(CPU_TYPE ${CMAKE_OSX_ARCHITECTURES}) @@ -34,16 +36,16 @@ option(LIBDDWAF_BUILD_SHARED "Build shared library" ON) option(LIBDDWAF_BUILD_STATIC "Build shared library" ON) -@@ -57,7 +57,7 @@ endif() +@@ -58,7 +58,7 @@ endif() include(GNUInstallDirs) -add_subdirectory(third_party) +#add_subdirectory(third_party) - set(LIBDDWAF_SOURCE - ${libddwaf_SOURCE_DIR}/src/ruleset_builder.cpp -@@ -137,7 +137,8 @@ install(FILES ${libddwaf_SOURCE_DIR}/include/ddwaf.h D + add_library(glibc_compat OBJECT ${libddwaf_SOURCE_DIR}/src/glibc-compat/time64.c) + set_target_properties(glibc_compat PROPERTIES POSITION_INDEPENDENT_CODE 1) +@@ -143,7 +143,8 @@ install(FILES ${libddwaf_SOURCE_DIR}/include/ddwaf.h D # System dependencies set(LIBDDWAF_INTERFACE_LIBRARIES "") @@ -51,9 +53,9 @@ +#set(LIBDDWAF_PRIVATE_LIBRARIES lib_re2 lib_ac lib_injection lib_radix lib_utf8proc) +set(LIBDDWAF_PRIVATE_LIBRARIES lib_radix) - if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux") - # needed for glibc <2.17. We compile with --as-needed so the library won't -@@ -165,6 +166,27 @@ if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux") + if(NOT MSVC AND LIBDDWAF_TEST_COVERAGE) + target_compile_options(libddwaf_objects PRIVATE -ggdb --coverage) +@@ -176,6 +177,27 @@ if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux") elseif(WIN32) list(APPEND LIBDDWAF_INTERFACE_LIBRARIES ws2_32) endif() @@ -81,7 +83,7 @@ target_link_libraries(libddwaf_objects PRIVATE ${LIBDDWAF_PRIVATE_LIBRARIES} -@@ -189,66 +211,67 @@ if (LIBDDWAF_BUILD_STATIC) +@@ -200,71 +222,72 @@ if (LIBDDWAF_BUILD_STATIC) INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) # Post-processing on the static library @@ -118,6 +120,7 @@ - COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ - COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ - COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ +- COMMAND ${CMAKE_COMMAND} -E copy $ ar_comb - COMMAND ${CMAKE_AR} -qcs ar_comb/combined${CMAKE_STATIC_LIBRARY_SUFFIX} ar_comb/*.o* - - COMMAND ${CMAKE_COMMAND} -E copy ar_comb/combined${CMAKE_STATIC_LIBRARY_SUFFIX} $ @@ -126,9 +129,13 @@ - endif() - if(NOT (CMAKE_BUILD_TYPE MATCHES Debug)) - if (CMAKE_SYSTEM_NAME STREQUAL Darwin OR CMAKE_SYSTEM_NAME STREQUAL Linux) -- find_program(STRIP strip) -- if (STRIP STREQUAL "STRIP-NOTFOUND") -- message(FATAL_ERROR "strip not found") +- if (NOT CMAKE_STRIP) +- find_program(STRIP strip) +- if (STRIP STREQUAL "STRIP-NOTFOUND") +- message(FATAL_ERROR "strip not found") +- endif() +- else() +- set(STRIP ${CMAKE_STRIP}) - endif() - add_custom_command(TARGET libddwaf_static POST_BUILD - COMMAND ${STRIP} -x -S $ -o $.stripped) @@ -169,6 +176,7 @@ +# COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ +# COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ +# COMMAND ${CMAKE_COMMAND} -E chdir ar_comb ${CMAKE_AR} -x $ ++# COMMAND ${CMAKE_COMMAND} -E copy $ ar_comb +# COMMAND ${CMAKE_AR} -qcs ar_comb/combined${CMAKE_STATIC_LIBRARY_SUFFIX} ar_comb/*.o* +# +# COMMAND ${CMAKE_COMMAND} -E copy ar_comb/combined${CMAKE_STATIC_LIBRARY_SUFFIX} $ @@ -177,9 +185,13 @@ +# endif() +# if(NOT (CMAKE_BUILD_TYPE MATCHES Debug)) +# if (CMAKE_SYSTEM_NAME STREQUAL Darwin OR CMAKE_SYSTEM_NAME STREQUAL Linux) -+# find_program(STRIP strip) -+# if (STRIP STREQUAL "STRIP-NOTFOUND") -+# message(FATAL_ERROR "strip not found") ++# if (NOT CMAKE_STRIP) ++# find_program(STRIP strip) ++# if (STRIP STREQUAL "STRIP-NOTFOUND") ++# message(FATAL_ERROR "strip not found") ++# endif() ++# else() ++# set(STRIP ${CMAKE_STRIP}) +# endif() +# add_custom_command(TARGET libddwaf_static POST_BUILD +# COMMAND ${STRIP} -x -S $ -o $.stripped) @@ -201,7 +213,7 @@ +# OUTPUT_VARIABLE BUILD_ID +# OUTPUT_STRIP_TRAILING_WHITESPACE +# ) -+ set(BUILD_ID "4be56b648aa8ce8b86255b0edad78862d102f65d") ++ set(BUILD_ID "25b0021f1d2ce1eea39a37ad41b6de9eec12ee84") message(STATUS "Build id is ${BUILD_ID}") string(SUBSTRING "${BUILD_ID}" 0 2 BUILD_ID_PREFIX) string(SUBSTRING "${BUILD_ID}" 2 39 BUILD_ID_SUFFIX) diff --git a/devel/libddwaf/files/patch-third_party-CMakeLists.txt b/devel/libddwaf/files/patch-third_party-CMakeLists.txt index bebea8992a61..41564fb5cdf0 100644 --- a/devel/libddwaf/files/patch-third_party-CMakeLists.txt +++ b/devel/libddwaf/files/patch-third_party-CMakeLists.txt @@ -1,4 +1,4 @@ ---- third_party/CMakeLists.txt.orig 2023-05-25 10:34:56 UTC +--- third_party/CMakeLists.txt.orig 2023-08-17 10:28:49 UTC +++ third_party/CMakeLists.txt @@ -15,24 +15,24 @@ if(NOT MSVC) set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wno-unused-parameter") @@ -42,7 +42,7 @@ target_compile_definitions(lib_rapidjson INTERFACE RAPIDJSON_HAS_STDSTRING=1) set_target_properties(proj_rapidjson PROPERTIES EXCLUDE_FROM_ALL TRUE) -@@ -45,153 +45,153 @@ endif() +@@ -45,32 +45,32 @@ endif() # To avoid building everything for re2, including test binvaries: # BUILD_COMMAND cmake --build --target re2 # But this is not enough, because the install target run afterwards insists on building everything @@ -61,6 +61,7 @@ - -DCMAKE_CXX_FLAGS_DEBUG=${CMAKE_CXX_FLAGS_DEBUG} - -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} - -DRE2_BUILD_TESTING=0 +- BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}re2${CMAKE_STATIC_LIBRARY_SUFFIX} -) +#set(RE2_COMMIT 885eb38accf49e2ccdd2fa6786f3590cf40a3e23) +#ExternalProject_Add(proj_re2 @@ -77,6 +78,7 @@ +# -DCMAKE_CXX_FLAGS_DEBUG=${CMAKE_CXX_FLAGS_DEBUG} +# -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} +# -DRE2_BUILD_TESTING=0 ++# BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}re2${CMAKE_STATIC_LIBRARY_SUFFIX} +#) # alas, we can't use find_package because by the package is not downloaded by config time # so manually creating the library @@ -95,6 +97,12 @@ +#endif() +#add_dependencies(lib_re2 proj_re2) + if(CMAKE_BUILD_TYPE MATCHES Debug) + set(LIBGTEST_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}gtestd${CMAKE_STATIC_LIBRARY_SUFFIX}) +@@ -81,54 +81,54 @@ else() + endif() + + -set(GOOGLETEST_COMMIT 955c7f837efad184ec63e771c42542d37545eaef) -ExternalProject_Add(proj_gtest - URL https://github.com/google/googletest/archive/${GOOGLETEST_COMMIT}.tar.gz @@ -110,12 +118,9 @@ - -DCMAKE_CXX_FLAGS_DEBUG=${CMAKE_CXX_FLAGS_DEBUG} - -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} - -DBUILD_SHARED_LIBS=0 +- -DBUILD_GMOCK=ON +- BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBGTEST_FILENAME} ${INSTALL_DIR}/lib/${LIBGMOCK_FILENAME} -) --if(CMAKE_BUILD_TYPE MATCHES Debug) -- set(LIBGTEST_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}gtestd${CMAKE_STATIC_LIBRARY_SUFFIX}) --else() -- set(LIBGTEST_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}gtest${CMAKE_STATIC_LIBRARY_SUFFIX}) --endif() +#set(GOOGLETEST_COMMIT 955c7f837efad184ec63e771c42542d37545eaef) +#ExternalProject_Add(proj_gtest +# URL https://github.com/google/googletest/archive/${GOOGLETEST_COMMIT}.tar.gz @@ -131,29 +136,34 @@ +# -DCMAKE_CXX_FLAGS_DEBUG=${CMAKE_CXX_FLAGS_DEBUG} +# -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} +# -DBUILD_SHARED_LIBS=0 ++# -DBUILD_GMOCK=ON ++# BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBGTEST_FILENAME} ${INSTALL_DIR}/lib/${LIBGMOCK_FILENAME} +#) -+#if(CMAKE_BUILD_TYPE MATCHES Debug) -+# set(LIBGTEST_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}gtestd${CMAKE_STATIC_LIBRARY_SUFFIX}) -+#else() -+# set(LIBGTEST_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}gtest${CMAKE_STATIC_LIBRARY_SUFFIX}) -+#endif() -add_library(lib_gtest STATIC IMPORTED GLOBAL) +-add_library(lib_gmock STATIC IMPORTED GLOBAL) -set_property(TARGET lib_gtest PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBGTEST_FILENAME}) +-set_property(TARGET lib_gmock PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBGMOCK_FILENAME}) -target_include_directories(lib_gtest INTERFACE ${INSTALL_DIR}/include) +-target_include_directories(lib_gmock INTERFACE ${INSTALL_DIR}/include) -if(NOT MSVC) - target_link_libraries(lib_gtest INTERFACE -lpthread) +- target_link_libraries(lib_gmock INTERFACE -lpthread) -endif() --add_dependencies(lib_gtest proj_gtest) --set_target_properties(lib_gtest proj_gtest PROPERTIES EXCLUDE_FROM_ALL TRUE) +#add_library(lib_gtest STATIC IMPORTED GLOBAL) ++#add_library(lib_gmock STATIC IMPORTED GLOBAL) +#set_property(TARGET lib_gtest PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBGTEST_FILENAME}) ++#set_property(TARGET lib_gmock PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBGMOCK_FILENAME}) +#target_include_directories(lib_gtest INTERFACE ${INSTALL_DIR}/include) ++#target_include_directories(lib_gmock INTERFACE ${INSTALL_DIR}/include) +#if(NOT MSVC) +# target_link_libraries(lib_gtest INTERFACE -lpthread) ++# target_link_libraries(lib_gmock INTERFACE -lpthread) +#endif() -+#add_dependencies(lib_gtest proj_gtest) -+#set_target_properties(lib_gtest proj_gtest PROPERTIES EXCLUDE_FROM_ALL TRUE) + + add_dependencies(lib_gtest proj_gtest) + add_dependencies(lib_gmock proj_gtest) + set_target_properties(lib_gtest lib_gmock proj_gtest PROPERTIES EXCLUDE_FROM_ALL TRUE) -add_library(lib_injection STATIC - libinjection/src/xss.c @@ -185,8 +195,9 @@ add_library(lib_radix STATIC radixlib/radixlib.c) - target_include_directories(lib_radix INTERFACE ${PROJECT_SOURCE_DIR}/radixlib) - set_target_properties(lib_radix PROPERTIES POSITION_INDEPENDENT_CODE 1) +@@ -141,74 +141,74 @@ else () + set(LIBUTF8PROC_FILENAME ${CMAKE_STATIC_LIBRARY_PREFIX}utf8proc${CMAKE_STATIC_LIBRARY_SUFFIX}) + endif() -set(UTF8PROC_VERSION v2.7.0) -ExternalProject_Add(proj_utf8proc @@ -202,6 +213,7 @@ - -DCMAKE_C_FLAGS_RELWITHDEBINFO=${CMAKE_C_FLAGS_RELWITHDEBINFO} - -DCMAKE_C_FLAGS_DEBUG=${CMAKE_C_FLAGS_DEBUG} - -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} +- BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBUTF8PROC_FILENAME} -) +#set(UTF8PROC_VERSION v2.7.0) +#ExternalProject_Add(proj_utf8proc @@ -217,26 +229,38 @@ +# -DCMAKE_C_FLAGS_RELWITHDEBINFO=${CMAKE_C_FLAGS_RELWITHDEBINFO} +# -DCMAKE_C_FLAGS_DEBUG=${CMAKE_C_FLAGS_DEBUG} +# -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} ++# BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBUTF8PROC_FILENAME} +#) -add_library(lib_utf8proc STATIC IMPORTED GLOBAL) --if (MSVC) -- set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}utf8proc_static${CMAKE_STATIC_LIBRARY_SUFFIX}) --else () -- set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}utf8proc${CMAKE_STATIC_LIBRARY_SUFFIX}) --endif() +-set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBUTF8PROC_FILENAME}) -target_include_directories(lib_utf8proc INTERFACE ${INSTALL_DIR}/include) -add_dependencies(lib_utf8proc proj_utf8proc) +#add_library(lib_utf8proc STATIC IMPORTED GLOBAL) -+#if (MSVC) -+# set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}utf8proc_static${CMAKE_STATIC_LIBRARY_SUFFIX}) -+#else () -+# set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}utf8proc${CMAKE_STATIC_LIBRARY_SUFFIX}) -+#endif() ++#set_property(TARGET lib_utf8proc PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBUTF8PROC_FILENAME}) +#target_include_directories(lib_utf8proc INTERFACE ${INSTALL_DIR}/include) +#add_dependencies(lib_utf8proc proj_utf8proc) # yaml-cpp +-if (NOT MSVC) +- if(CMAKE_BUILD_TYPE MATCHES Debug) +- set(LIBYAML_FILENAME libyaml-cppd${CMAKE_STATIC_LIBRARY_SUFFIX}) +- else() +- set(LIBYAML_FILENAME libyaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) +- endif() +-else() +- set(LIBYAML_FILENAME yaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) +-endif() ++#if (NOT MSVC) ++# if(CMAKE_BUILD_TYPE MATCHES Debug) ++# set(LIBYAML_FILENAME libyaml-cppd${CMAKE_STATIC_LIBRARY_SUFFIX}) ++# else() ++# set(LIBYAML_FILENAME libyaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) ++# endif() ++#else() ++# set(LIBYAML_FILENAME yaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) ++#endif() + -ExternalProject_Add(proj_yamlcpp - URL https://github.com/jbeder/yaml-cpp/archive/refs/tags/yaml-cpp-0.7.0.zip - INSTALL_DIR ${INSTALL_DIR} @@ -256,17 +280,13 @@ - -DYAML_MSVC_SHARED_RT=OFF - -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE} - -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} +- BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBYAML_FILENAME} -) -add_library(lib_yamlcpp STATIC IMPORTED GLOBAL) --if (NOT MSVC) -- if(CMAKE_BUILD_TYPE MATCHES Debug) -- set(LIBYAML_FILENAME libyaml-cppd${CMAKE_STATIC_LIBRARY_SUFFIX}) -- else() -- set(LIBYAML_FILENAME libyaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) -- endif() --else() -- set(LIBYAML_FILENAME yaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) --endif() +-set_target_properties(lib_yamlcpp PROPERTIES IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBYAML_FILENAME}) +-target_include_directories(lib_yamlcpp INTERFACE ${INSTALL_DIR}/include) +-add_dependencies(lib_yamlcpp proj_yamlcpp) +-set_target_properties(lib_yamlcpp proj_yamlcpp PROPERTIES EXCLUDE_FROM_ALL TRUE) +#ExternalProject_Add(proj_yamlcpp +# URL https://github.com/jbeder/yaml-cpp/archive/refs/tags/yaml-cpp-0.7.0.zip +# INSTALL_DIR ${INSTALL_DIR} @@ -286,22 +306,9 @@ +# -DYAML_MSVC_SHARED_RT=OFF +# -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE} +# -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES} ++# BUILD_BYPRODUCTS ${INSTALL_DIR}/lib/${LIBYAML_FILENAME} +#) +#add_library(lib_yamlcpp STATIC IMPORTED GLOBAL) -+#if (NOT MSVC) -+# if(CMAKE_BUILD_TYPE MATCHES Debug) -+# set(LIBYAML_FILENAME libyaml-cppd${CMAKE_STATIC_LIBRARY_SUFFIX}) -+# else() -+# set(LIBYAML_FILENAME libyaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) -+# endif() -+#else() -+# set(LIBYAML_FILENAME yaml-cpp${CMAKE_STATIC_LIBRARY_SUFFIX}) -+#endif() - --set_target_properties(lib_yamlcpp PROPERTIES IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBYAML_FILENAME}) --target_include_directories(lib_yamlcpp INTERFACE ${INSTALL_DIR}/include) --add_dependencies(lib_yamlcpp proj_yamlcpp) --set_target_properties(lib_yamlcpp proj_yamlcpp PROPERTIES EXCLUDE_FROM_ALL TRUE) +#set_target_properties(lib_yamlcpp PROPERTIES IMPORTED_LOCATION ${INSTALL_DIR}/lib/${LIBYAML_FILENAME}) +#target_include_directories(lib_yamlcpp INTERFACE ${INSTALL_DIR}/include) +#add_dependencies(lib_yamlcpp proj_yamlcpp)