Skip to content

Commit 659f470

Browse files
committed
Replace FindPythonInterp with what cmake 4.0 wants.
1 parent f76b563 commit 659f470

4 files changed

Lines changed: 12 additions & 14 deletions

File tree

cmakelib/QuickCppLibApplyDefaultDefinitions.cmake

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -200,12 +200,14 @@ if(TARGET ${PROJECT_NAME}_dl)
200200
)
201201
endif()
202202

203-
option(ENABLE_VALGRIND "Compiles in valgrind instrumentation such that locks are checked for correctness etc in optimised builds. Always on in Debug builds, defaults to off in optimised builds" OFF)
204-
if(ENABLE_VALGRIND)
205-
indented_message(STATUS "ENABLE_VALGRIND=ON: Compiling in valgrind instrumentation so correctness can be checked")
206-
all_compile_definitions(PUBLIC QUICKCPPLIB_ENABLE_VALGRIND=1)
207-
else()
208-
all_compile_definitions(PUBLIC $<$<CONFIG:Debug>:QUICKCPPLIB_ENABLE_VALGRIND=1>)
203+
if(NOT DISABLE_VALGRIND)
204+
option(ENABLE_VALGRIND "Compiles in valgrind instrumentation such that locks are checked for correctness etc in optimised builds. Always on in Debug builds, defaults to off in optimised builds" OFF)
205+
if(ENABLE_VALGRIND)
206+
indented_message(STATUS "ENABLE_VALGRIND=ON: Compiling in valgrind instrumentation so correctness can be checked")
207+
all_compile_definitions(PUBLIC QUICKCPPLIB_ENABLE_VALGRIND=1)
208+
else()
209+
all_compile_definitions(PUBLIC $<$<CONFIG:Debug>:QUICKCPPLIB_ENABLE_VALGRIND=1>)
210+
endif()
209211
endif()
210212

211213
all_target_output_properties(PROPERTIES

cmakelib/QuickCppLibPolicies.cmake

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,3 @@ endif()
99
if (POLICY CMP0091)
1010
cmake_policy(SET CMP0091 NEW)
1111
endif()
12-
# want FindPythonInterp
13-
if (POLICY CMP0148)
14-
cmake_policy(SET CMP0148 OLD)
15-
endif()

cmakelib/QuickCppLibSetupProject.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ include(CTest)
1010
find_package(Threads)
1111
link_libraries(${CMAKE_THREAD_LIBS_INIT})
1212
# Find a python installation, if we have one we can do preprocessing
13-
include(FindPythonInterp)
13+
find_package(Python COMPONENTS Interpreter)
1414

1515
# Configure an if(CLANG) and if(GCC) like if(MSVC)
1616
if(NOT DEFINED CLANG)

include/quickcpplib/revision.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
// Note the second line of this file must ALWAYS be the git SHA, third line ALWAYS the git SHA update time
2-
#define QUICKCPPLIB_PREVIOUS_COMMIT_REF 490eb2ed3b6d0176bf6b2b3c6667c182559c8bb9
3-
#define QUICKCPPLIB_PREVIOUS_COMMIT_DATE "2025-02-03 11:27:23 +00:00"
4-
#define QUICKCPPLIB_PREVIOUS_COMMIT_UNIQUE 490eb2ed
2+
#define QUICKCPPLIB_PREVIOUS_COMMIT_REF f76b563be131145fd83a6dd5b9741c23dc4d794c
3+
#define QUICKCPPLIB_PREVIOUS_COMMIT_DATE "2025-05-20 18:36:46 +00:00"
4+
#define QUICKCPPLIB_PREVIOUS_COMMIT_UNIQUE f76b563b

0 commit comments

Comments
 (0)