From e54f2773d3efb9b150ed583a00b79f36dcb23149 Mon Sep 17 00:00:00 2001 From: Hparty <420024556@qq.com> Date: Fri, 6 Dec 2024 21:32:31 +0800 Subject: [PATCH] Fix pipeline issues # Conflicts: # src/rendering/filters/layerstyle/EffectFilter.cpp --- CMakeLists.txt | 7 +++++++ autotest.sh | 2 +- update_baseline.sh | 4 ++-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c00116c93e..0443d2b94f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -27,6 +27,10 @@ option(PAG_USE_RTTR "Enable RTTR support" OFF) option(PAG_USE_HARFBUZZ "Enable HarfBuzz support" OFF) option(PAG_USE_C "Enable c API" OFF) +if (CMAKE_BUILD_TYPE STREQUAL "Debug") + option(PAG_ENABLE_PROFILING "Enable Profiling" ON) +endif () + if (NOT MACOS AND NOT IOS AND NOT WEB) option(PAG_USE_FREETYPE "Allow use of embedded freetype library" ON) endif () @@ -99,6 +103,7 @@ message("PAG_USE_C: ${PAG_USE_C}") message("PAG_BUILD_SHARED: ${PAG_BUILD_SHARED}") message("PAG_BUILD_FRAMEWORK: ${PAG_BUILD_FRAMEWORK}") message("PAG_BUILD_TESTS: ${PAG_BUILD_TESTS}") +message("PAG_ENABLE_PROFILING: ${PAG_ENABLE_PROFILING}") if (NOT CMAKE_OSX_DEPLOYMENT_TARGET) if (DEPLOYMENT_TARGET) @@ -433,6 +438,7 @@ if (NOT HAS_CUSTOM_TGFX_DIR AND EXISTS ${TGFX_CACHE_DIR}) list(APPEND TGFX_OPTIONS "-DTGFX_USE_JPEG_ENCODE=${PAG_USE_JPEG_ENCODE}") list(APPEND TGFX_OPTIONS "-DTGFX_USE_WEBP_DECODE=${PAG_USE_WEBP_DECODE}") list(APPEND TGFX_OPTIONS "-DTGFX_USE_WEBP_ENCODE=${PAG_USE_WEBP_ENCODE}") + list(APPEND TGFX_OPTIONS "-DTGFX_ENABLE_PROFILING=${PAG_ENABLE_PROFILING}") if (PAG_USE_QT) list(APPEND TGFX_OPTIONS "-DCMAKE_PREFIX_PATH=\"${CMAKE_PREFIX_PATH}\"") endif () @@ -463,6 +469,7 @@ else () set(TGFX_USE_JPEG_ENCODE ${PAG_USE_JPEG_ENCODE}) set(TGFX_USE_WEBP_DECODE ${PAG_USE_WEBP_DECODE}) set(TGFX_USE_WEBP_ENCODE ${PAG_USE_WEBP_ENCODE}) + set(TGFX_ENABLE_PROFILING ${PAG_ENABLE_PROFILING}) set(CMAKE_POLICY_DEFAULT_CMP0077 NEW) add_subdirectory(${TGFX_DIR} tgfx EXCLUDE_FROM_ALL) list(APPEND PAG_STATIC_LIBS $) diff --git a/autotest.sh b/autotest.sh index d9f42c33c0..2a9899feb6 100755 --- a/autotest.sh +++ b/autotest.sh @@ -25,7 +25,7 @@ make_dir result make_dir build cd build -cmake -DCMAKE_CXX_FLAGS="-fprofile-arcs -ftest-coverage -g -O0" -DPAG_USE_SWIFTSHADER=ON -DPAG_BUILD_TESTS=ON -DCMAKE_BUILD_TYPE=Debug ../ +cmake -DCMAKE_CXX_FLAGS="-fprofile-arcs -ftest-coverage -g -O0" -DPAG_USE_SWIFTSHADER=ON -DPAG_BUILD_TESTS=ON -DPAG_ENABLE_PROFILING=OFF -DCMAKE_BUILD_TYPE=Debug ../ if test $? -eq 0; then echo "~~~~~~~~~~~~~~~~~~~CMakeLists OK~~~~~~~~~~~~~~~~~~" else diff --git a/update_baseline.sh b/update_baseline.sh index 6c0565c375..5edb7bfc53 100755 --- a/update_baseline.sh +++ b/update_baseline.sh @@ -43,9 +43,9 @@ echo $CMAKE_COMMAND if [[ $1 == "1" ]]; then - $CMAKE_COMMAND -DCMAKE_CXX_FLAGS="-fprofile-arcs -ftest-coverage -g -O0" -DPAG_USE_SWIFTSHADER=ON -DPAG_BUILD_TESTS=ON -DPAG_SKIP_BASELINE_CHECK=ON -DCMAKE_BUILD_TYPE=Debug ../ + $CMAKE_COMMAND -DCMAKE_CXX_FLAGS="-fprofile-arcs -ftest-coverage -g -O0" -DPAG_USE_SWIFTSHADER=ON -DPAG_BUILD_TESTS=ON -DPAG_SKIP_BASELINE_CHECK=ON -DPAG_ENABLE_PROFILING=OFF -DCMAKE_BUILD_TYPE=Debug ../ else - $CMAKE_COMMAND -DPAG_BUILD_TESTS=ON -DPAG_SKIP_BASELINE_CHECK=ON -DCMAKE_BUILD_TYPE=Debug ../ + $CMAKE_COMMAND -DPAG_BUILD_TESTS=ON -DPAG_SKIP_BASELINE_CHECK=ON -DPAG_ENABLE_PROFILING=OFF -DCMAKE_BUILD_TYPE=Debug ../ fi $CMAKE_COMMAND --build . --target UpdateBaseline -- -j 12