diff --git a/CMakeLists.txt b/CMakeLists.txt index f4f90e62..f706bc20 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,7 @@ project(rosjava_bootstrap) find_package(catkin REQUIRED rosjava_build_tools) -catkin_rosjava_setup(publish installDist) +catkin_rosjava_setup(publish install) catkin_package() @@ -19,5 +19,5 @@ catkin_package() # Installation ############################################################################## -install(DIRECTORY ${CATKIN_DEVEL_PREFIX}/${CATKIN_GLOBAL_MAVEN_DESTINATION}/org/ros/rosjava_bootstrap/ - DESTINATION ${CATKIN_GLOBAL_MAVEN_DESTINATION}/org/ros/rosjava_bootstrap) +install(DIRECTORY ${ROS_MAVEN_DEPLOYMENT_REPOSITORY}/org/ros/rosjava_bootstrap + DESTINATION ${CATKIN_GLOBAL_MAVEN_DESTINATION}/org/ros) diff --git a/message_generation/src/main/java/org/ros/internal/message/GenerateInterfaces.java b/message_generation/src/main/java/org/ros/internal/message/GenerateInterfaces.java index 64a16c89..33f23cdf 100644 --- a/message_generation/src/main/java/org/ros/internal/message/GenerateInterfaces.java +++ b/message_generation/src/main/java/org/ros/internal/message/GenerateInterfaces.java @@ -142,6 +142,27 @@ public void generate(File outputDirectory, Collection packages, for (File directory : packagePath) { topicDefinitionFileProvider.addDirectory(directory); serviceDefinitionFileProvider.addDirectory(directory); + + //ugly hack for action definitions + String dir = directory.getAbsolutePath(); + String actionDir = dir + "/action"; + File actionFile = new File(actionDir); + if(actionFile.exists()) { + int idx = dir.indexOf("src"); + if(idx >= 0){ + String subDir = dir.substring(idx); + dir = dir.replace(subDir,"devel/share/"); + String[] splits = directory.getAbsolutePath().split("/"); + if(splits.length >0){ + dir += splits[splits.length-1]; + File newFileDir = new File(dir); + if(newFileDir.exists()){ + topicDefinitionFileProvider.addDirectory(newFileDir); + } + } + } + } + } topicDefinitionFileProvider.update(); serviceDefinitionFileProvider.update();