libftdi-git Archives

Subject: A library to talk to FTDI chips branch, master, updated. v1.5-66-gf7ed9dd

From: libftdi-git@xxxxxxxxxxxxxxxxxxxxxxx
To: libftdi-git@xxxxxxxxxxxxxxxxxxxxxxx
Date: Mon, 30 Jun 2025 13:32:02 +0200 (CEST)
The branch, master has been updated
       via  f7ed9dd371f9387ed5b715a4f316eea9f85de48d (commit)
      from  eaf42c00bfab5d6bbd8106b11a697ff4f2d7659f (commit)


- Log -----------------------------------------------------------------
commit f7ed9dd371f9387ed5b715a4f316eea9f85de48d
Author: Yegor Yefremov <yegorslists@xxxxxxxxxxxxxx>
Date:   Mon Jun 23 14:44:13 2025 +0200

    python/CMakeLists.txt: rework Python development files detection
    
    Both the FindPythonInterp and FindPythonLibs modules were removed. Use
    find_package(Python3 COMPONENTS Interpreter Development) to find both
    the interpreter and the library.
    
    The old modules have been deprecated since CMake 3.12.
    
    Resolves the following warning:
    
    CMake Warning (dev) at python/CMakeLists.txt:11 (find_package):
      Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules
      are removed.  Run "cmake --help-policy CMP0148" for policy details.  Use
      the cmake_policy command to set the policy and suppress this warning.

-----------------------------------------------------------------------

Summary of changes:
 python/CMakeLists.txt |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
index d496c3f..d312fae 100644
--- a/python/CMakeLists.txt
+++ b/python/CMakeLists.txt
@@ -8,12 +8,11 @@ else ()
         set(SWIG_FOUND TRUE)
     endif ()
 endif ()
-find_package(PythonInterp REQUIRED)
-find_package(PythonLibs REQUIRED)
+find_package(Python3 COMPONENTS Interpreter Development)
 
 include(UseSWIG)
 include_directories(BEFORE ${PROJECT_SOURCE_DIR}/src)
-include_directories(${PYTHON_INCLUDE_DIRS})
+include_directories(${Python3_INCLUDE_DIRS})
 link_directories(${CMAKE_CURRENT_BINARY_DIR}/../src)
 
 if (DOCUMENTATION)
@@ -32,7 +31,7 @@ endif ()
 
 set_target_properties(pyftdi1 PROPERTIES NO_SONAME ON)
 
-execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "import sysconfig; print( 
sysconfig.get_path( 'platlib', vars={'platbase': '${CMAKE_INSTALL_PREFIX}'} ) )"
+execute_process(COMMAND ${Python3_EXECUTABLE} -c "import sysconfig; print( 
sysconfig.get_path( 'platlib', vars={'platbase': '${CMAKE_INSTALL_PREFIX}'} ) )"
         OUTPUT_VARIABLE _ABS_PYTHON_MODULE_PATH
         OUTPUT_STRIP_TRAILING_WHITESPACE)
 
@@ -55,7 +54,7 @@ if (DOCUMENTATION)
 
     # generate .i from doxygen .xml
     add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/ftdi1_doc.i
-            COMMAND ${PYTHON_EXECUTABLE} 
${CMAKE_CURRENT_SOURCE_DIR}/doxy2swig.py -n
+            COMMAND ${Python3_EXECUTABLE} 
${CMAKE_CURRENT_SOURCE_DIR}/doxy2swig.py -n
             ${PROJECT_BINARY_DIR}/doc/xml/ftdi_8c.xml
             ${CMAKE_CURRENT_BINARY_DIR}/ftdi1_doc.i
             COMMENT "Generating ftdi1_doc.i from ftdi_8c.xml"


hooks/post-receive
-- 
A library to talk to FTDI chips

--
libftdi-git - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi-git+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx   

Current Thread
  • A library to talk to FTDI chips branch, master, updated. v1.5-66-gf7ed9dd, libftdi-git <=