From ea7bed3a096949588b1b9086ddf66b2f7892a385 Mon Sep 17 00:00:00 2001 From: Mattias Ellert Date: Thu, 4 Dec 2025 23:13:28 +0100 Subject: [PATCH] Dont export Python modules --- bindings/pyroot/cppyy/CPyCppyy/CMakeLists.txt | 3 +-- bindings/pyroot/pythonizations/CMakeLists.txt | 9 +-------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/bindings/pyroot/cppyy/CPyCppyy/CMakeLists.txt b/bindings/pyroot/cppyy/CPyCppyy/CMakeLists.txt index 95ca00bde9f..a12d3f05e4d 100644 --- a/bindings/pyroot/cppyy/CPyCppyy/CMakeLists.txt +++ b/bindings/pyroot/cppyy/CPyCppyy/CMakeLists.txt @@ -120,8 +120,7 @@ install(TARGETS CPyCppyy EXPORT ${CMAKE_PROJECT_NAME}Exports LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries) -install(TARGETS cppyy EXPORT ${CMAKE_PROJECT_NAME}Exports - RUNTIME DESTINATION ${CPPYY_INSTALL_DIR} COMPONENT libraries # Windows +install(TARGETS cppyy RUNTIME DESTINATION ${CPPYY_INSTALL_DIR} COMPONENT libraries # Windows LIBRARY DESTINATION ${CPPYY_INSTALL_DIR} COMPONENT libraries ARCHIVE DESTINATION ${CPPYY_INSTALL_DIR} COMPONENT libraries) diff --git a/bindings/pyroot/pythonizations/CMakeLists.txt b/bindings/pyroot/pythonizations/CMakeLists.txt index 32d7d54b8da..5128e6d337c 100644 --- a/bindings/pyroot/pythonizations/CMakeLists.txt +++ b/bindings/pyroot/pythonizations/CMakeLists.txt @@ -63,12 +63,6 @@ if(NOT MSVC) target_compile_options(${libname} PRIVATE -Wno-strict-aliasing) endif() - -# Create meta-target PyROOT3 (INTERFACE library) -# Export of targets are not supported for custom targets(add_custom_targets()) -add_library(PyROOT INTERFACE) -target_link_libraries(PyROOT INTERFACE cppyy_backend cppyy ROOTPythonizations) - # Define library output directories for build and install trees set(pymoduledir_build "${localruntimedir}/ROOT") set(pymoduledir_install "${CMAKE_INSTALL_PYTHONDIR}/ROOT") @@ -93,8 +87,7 @@ if(NOT MSVC) endif() # Install library -install(TARGETS ${libname} EXPORT ${CMAKE_PROJECT_NAME}Exports - RUNTIME DESTINATION ${pymoduledir_install} COMPONENT libraries +install(TARGETS ${libname} RUNTIME DESTINATION ${pymoduledir_install} COMPONENT libraries LIBRARY DESTINATION ${pymoduledir_install} COMPONENT libraries ARCHIVE DESTINATION ${pymoduledir_install} COMPONENT libraries) -- 2.55.0