From 4d77588c299093074eee7d01c7dfe36a778fa296 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ricardo=20Gonz=C3=A1lez=20Moreno?= Date: Mon, 1 Jul 2024 08:53:27 +0200 Subject: [PATCH] Refs #21268. Regenerate code MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ricardo González Moreno --- fastdds_python/test/types/CMakeLists.txt | 21 ++++++++++++++++--- .../HelloWorldExample/CMakeLists.txt | 7 ++++++- 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/fastdds_python/test/types/CMakeLists.txt b/fastdds_python/test/types/CMakeLists.txt index 876c696a..c1815bc9 100644 --- a/fastdds_python/test/types/CMakeLists.txt +++ b/fastdds_python/test/types/CMakeLists.txt @@ -48,7 +48,12 @@ target_link_libraries(${PROJECT_NAME} ############################################################################### # Python bindings for type -find_package(SWIG REQUIRED) +find_package(SWIG) +if (NOT SWIG_FOUND) + # Trick to find swig4.1 in Ubuntu noble. + find_program(SWIG_EXECUTABLE NAMES swig4.1 swig) + find_package(SWIG REQUIRED) +endif() include(${SWIG_USE_FILE}) set(CMAKE_SWIG_FLAGS "") @@ -148,7 +153,12 @@ target_link_libraries(${PROJECT_NAME} ############################################################################### # Python bindings for type -find_package(SWIG REQUIRED) +find_package(SWIG) +if (NOT SWIG_FOUND) + # Trick to find swig4.1 in Ubuntu noble. + find_program(SWIG_EXECUTABLE NAMES swig4.1 swig) + find_package(SWIG REQUIRED) +endif() include(${SWIG_USE_FILE}) set(CMAKE_SWIG_FLAGS "") @@ -249,7 +259,12 @@ target_link_libraries(${PROJECT_NAME} ############################################################################### # Python bindings for type -find_package(SWIG REQUIRED) +find_package(SWIG) +if (NOT SWIG_FOUND) + # Trick to find swig4.1 in Ubuntu noble. + find_program(SWIG_EXECUTABLE NAMES swig4.1 swig) + find_package(SWIG REQUIRED) +endif() include(${SWIG_USE_FILE}) set(CMAKE_SWIG_FLAGS "") diff --git a/fastdds_python_examples/HelloWorldExample/CMakeLists.txt b/fastdds_python_examples/HelloWorldExample/CMakeLists.txt index 84a53ee6..89735e43 100644 --- a/fastdds_python_examples/HelloWorldExample/CMakeLists.txt +++ b/fastdds_python_examples/HelloWorldExample/CMakeLists.txt @@ -48,7 +48,12 @@ target_link_libraries(${PROJECT_NAME} ############################################################################### # Python bindings for type -find_package(SWIG REQUIRED) +find_package(SWIG) +if (NOT SWIG_FOUND) + # Trick to find swig4.1 in Ubuntu noble. + find_program(SWIG_EXECUTABLE NAMES swig4.1 swig) + find_package(SWIG REQUIRED) +endif() include(${SWIG_USE_FILE}) set(CMAKE_SWIG_FLAGS "")