Skip to content

Commit

Permalink
Stop using python_cmake_module.
Browse files Browse the repository at this point in the history
We really don't need it anymore, and can just use the
builtin find_package(Python3).

Signed-off-by: Chris Lalancette <clalancette@gmail.com>
  • Loading branch information
clalancette committed Jun 4, 2024
1 parent 179f688 commit 44f78b8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
3 changes: 0 additions & 3 deletions rosidl_generator_py/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,6 @@ if(BUILD_TESTING)

find_package(test_interface_files REQUIRED)

find_package(python_cmake_module REQUIRED)
find_package(PythonExtra MODULE REQUIRED)

include(cmake/register_py.cmake)
include(cmake/rosidl_generator_py_get_typesupports.cmake)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.

find_package(python_cmake_module REQUIRED)
find_package(PythonExtra REQUIRED)
find_package(rmw REQUIRED)
find_package(rosidl_runtime_c REQUIRED)
find_package(rosidl_typesupport_c REQUIRED)
Expand Down Expand Up @@ -184,7 +182,9 @@ foreach(_typesupport_impl ${_typesupport_impls})
${rosidl_generate_interfaces_TARGET}__rosidl_typesupport_c
)

set_target_properties(${_target_name} PROPERTIES DEBUG_POSTFIX "${PythonExtra_POSTFIX}")
if(WIN32 AND CMAKE_BUILD_TYPE STREQUAL "Debug")
set_target_properties(${_target_name} PROPERTIES DEBUG_POSTFIX "_d")
endif()
# target_compile_options(${_target_name} PRIVATE ${_extension_compile_flags})
# TODO(sloretz) use target_compile_options when python extension passes -Wpedantic
set_target_properties(${_target_name} PROPERTIES COMPILE_OPTIONS "${_extension_compile_flags}")
Expand Down
2 changes: 0 additions & 2 deletions rosidl_generator_py/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@

<buildtool_export_depend>ament_cmake</buildtool_export_depend>
<buildtool_export_depend>ament_index_python</buildtool_export_depend>
<buildtool_export_depend>python_cmake_module</buildtool_export_depend>
<buildtool_export_depend>rosidl_generator_c</buildtool_export_depend>
<buildtool_export_depend>rosidl_pycommon</buildtool_export_depend>
<buildtool_export_depend>rosidl_typesupport_c</buildtool_export_depend>
Expand Down Expand Up @@ -53,7 +52,6 @@
<test_depend>ament_lint_common</test_depend>
<test_depend>python3-numpy</test_depend>
<test_depend>python3-pytest</test_depend>
<test_depend>python_cmake_module</test_depend>
<test_depend>rmw</test_depend>
<test_depend>rosidl_cmake</test_depend>

Expand Down

0 comments on commit 44f78b8

Please sign in to comment.