Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[audio_to_spectrogram] Fix when to use catkin_install_python #2859

Merged
merged 1 commit into from
Dec 13, 2024

Conversation

pazeshun
Copy link
Contributor

I found another issue of #2743 other than #2851.

Conditional branch for catkin_install_python is wrong only in audio_to_spectrogram.

Correct (jsk_recognition_msgs):

if($ENV{ROS_DISTRO} STREQUAL "indigo") # on noetic it needs catkin_install_python to support Python3 and it does not work on indigo for some reason...
install(DIRECTORY scripts
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
USE_SOURCE_PERMISSIONS
)
else()
install(DIRECTORY scripts
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
USE_SOURCE_PERMISSIONS
PATTERN "*"
PATTERN "*/*.py" EXCLUDE
)
file(GLOB SCRIPT_PROGRAMS scripts/*.py)
catkin_install_python(
PROGRAMS ${SCRIPT_PROGRAMS}
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/scripts
)
endif()

On indigo, catkin_install_python is not used.

Wrong (audio_to_spectrogram):

if(NOT $ENV{ROS_DISTRO} STREQUAL "indigo") # on noetic it needs catkin_install_python to support Python3 and it does not work on indigo for some reason...
install(DIRECTORY scripts
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
USE_SOURCE_PERMISSIONS
)
else()
install(DIRECTORY scripts
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
USE_SOURCE_PERMISSIONS
PATTERN "*"
PATTERN "*/*.py" EXCLUDE
)
file(GLOB SCRIPT_PROGRAMS scripts/*.py)
catkin_install_python(
PROGRAMS ${SCRIPT_PROGRAMS}
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/scripts
)
endif()

Not on indigo, catkin_install_python is not used.

@k-okada k-okada merged commit 166151d into jsk-ros-pkg:master Dec 13, 2024
11 checks passed
@pazeshun pazeshun deleted the fix-install branch December 13, 2024 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants