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

skip if interface name is duplicated. #1051

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions rtmbuild/cmake/servicebridge.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,23 @@ macro(_rtmbuild_genbridge_init)

string(REPLACE "\n" ";" ${PROJECT_NAME}_autogen_files ${${PROJECT_NAME}_autogen_files})
##
## if one of the autogen files are already installed, skip this.
set(_interface_name "")
foreach(_autogen_file ${${PROJECT_NAME}_autogen_files})
get_filename_component(_ext ${_autogen_file} EXT)
if(NOT _ext)
set(_interface_name ${_autogen_file})
endif()
endforeach()
if(DEBUG_RTMBUILD_CMAKE)
message("[_rtmbuild_genbridge_init] Convert ${_idl_file} as ${_interface_name} interface")
endif()
list(FIND ${PROJECT_NAME}_autogen_interfaces ${_interface_name} _found_interface_name)
if(${_found_interface_name} GREATER -1)
message(WARNING "Duplicate interface name ${_interface_name} (${_idl_name}), as of 2018, we do not find the solution to fix this without breaking API (https://github.com/start-jsk/rtmros_common/pull/1046)")
break() # skip to next loop
endif()
##
## set _autogen_msg_files, _autogen_srv_files
if(DEBUG_RTMBUILD_CMAKE)
message("[_rtmbuild_genbridge_init] ${PROJECT_NAME}_autogen_files : ${${PROJECT_NAME}_autogen_files}")
Expand Down