diff options
-rw-r--r-- | rosgpt.spec | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/rosgpt.spec b/rosgpt.spec index 39daf74..dc0adc0 100644 --- a/rosgpt.spec +++ b/rosgpt.spec @@ -20,13 +20,19 @@ Source0: %{name}_%{version}.orig.tar.gz Requires: ros-%{ros_distro}-rclcpp Requires: ros-%{ros_distro}-sensor-msgs Requires: ros-%{ros_distro}-std-msgs -Requires: ros-%{ros_distro}-ros-workspace +Requires: ros-%{ros_distro}-nav2-msgs +Requires: ros-%{ros_distro}-rclpy +Requires: ros-%{ros_distro}-ament-package +Requires: python3-setuptools -BuildRequires: ros-%{ros_distro}-ros-workspace BuildRequires: ros-%{ros_distro}-rclcpp +BuildRequires: python3-setuptools +BuildRequires: ros-%{ros_distro}-ament-package +BuildRequires: ros-%{ros_distro}-rclpy BuildRequires: ros-%{ros_distro}-sensor-msgs BuildRequires: ros-%{ros_distro}-std-msgs BuildRequires: ros-%{ros_distro}-ament-cmake +BuildRequires: ros-%{ros_distro}-nav2-msgs %if 0%{?with_tests} BuildRequires: ros-%{ros_distro}-launch_testing_ament_cmake @@ -58,9 +64,10 @@ export ROS_PYTHON_VERSION=%{python3_version} # in the install tree and source it. It will set things like # CMAKE_PREFIX_PATH, PKG_CONFIG_PATH, and PYTHONPATH. if [ -f "/opt/ros/%{ros_distro}/setup.sh" ]; then . "/opt/ros/%{ros_distro}/setup.sh"; fi -mkdir -p .obj-%{_target_platform} && cd .obj-%{_target_platform} %py3_build +%make_build + %install # Needed to bootstrap since the ros_workspace package does not yet exist. export PYTHONPATH=/opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages @@ -83,8 +90,7 @@ if [ -n "$TEST_TARGET" ]; then # in the install tree and source it. It will set things like # CMAKE_PREFIX_PATH, PKG_CONFIG_PATH, and PYTHONPATH. if [ -f "/opt/ros/%{ros_distro}/setup.sh" ]; then . "/opt/ros/%{ros_distro}/setup.sh"; fi -CTEST_OUTPUT_ON_FAILURE=1 \ - %make_build -C .obj-%{_target_platform} $TEST_TARGET || echo "RPM TESTS FAILED" +%__python3 -m pytest $TEST_TARGET || echo "RPM TESTS FAILED" else echo "RPM TESTS SKIPPED"; fi %endif |