Skip to content

Commit

Permalink
Merge branch 'review-cmake' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
jgvictores committed Mar 23, 2018
2 parents 5565536 + 3ae0732 commit 74a68d0
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 14 deletions.
19 changes: 18 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,28 @@ set_property(GLOBAL PROPERTY ROBOTICSLAB_SPEECH_IDL_SOURCES)
# Store list of exported targets in global scope.
set_property(GLOBAL PROPERTY ROBOTICSLAB_SPEECH_TARGETS)

# Create targets if specific requirements are satisfied.
include(CMakeDependentOption)

# Find YARP (main dependency).
find_package(YARP REQUIRED)

# Load YARP modules.
if(YARP_VERSION_SHORT VERSION_LESS 2.3.70)
list(APPEND CMAKE_MODULE_PATH ${YARP_MODULE_PATH})
include(YarpPlugin)
include(YarpInstallationHelpers)
endif()

# Configure installation paths for YARP resources.
yarp_configure_external_installation(roboticslab-speech WITH_PLUGINS)

# Add main contents.
add_subdirectory(cmake)
add_subdirectory(share)
add_subdirectory(libraries)
add_subdirectory(programs)
#add_subdirectory(tests)
add_subdirectory(share)

# Store the package in the user registry.
export(PACKAGE ROBOTICSLAB_SPEECH)
Expand Down
5 changes: 0 additions & 5 deletions libraries/YarpPlugins/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@
# Authors: Juan G. Victores & Raul de Santos Rico
# CopyPolicy: Released under the terms of the LGPLv2.1 or later, see LGPL.TXT

# Find YARP (common dependency for all devices).
find_package(YARP REQUIRED)

if(YARP_VERSION_SHORT VERSION_LESS 2.3.70)
list(APPEND CMAKE_MODULE_PATH ${YARP_MODULE_PATH})
include(YarpPlugin)
include_directories(${YARP_INCLUDE_DIRS})
endif()

Expand Down
6 changes: 3 additions & 3 deletions libraries/YarpPlugins/Espeak/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ if(NOT SKIP_Espeak)

yarp_install(TARGETS Espeak
COMPONENT runtime
LIBRARY DESTINATION ${YARP_DYNAMIC_PLUGINS_INSTALL_DIR}
ARCHIVE DESTINATION ${YARP_STATIC_PLUGINS_INSTALL_DIR})
LIBRARY DESTINATION ${ROBOTICSLAB-SPEECH_DYNAMIC_PLUGINS_INSTALL_DIR}
ARCHIVE DESTINATION ${ROBOTICSLAB-SPEECH_STATIC_PLUGINS_INSTALL_DIR})

yarp_install(FILES Espeak.ini
COMPONENT runtime
DESTINATION ${YARP_PLUGIN_MANIFESTS_INSTALL_DIR})
DESTINATION ${ROBOTICSLAB-SPEECH_PLUGIN_MANIFESTS_INSTALL_DIR})

# Already included in /share?
if(NOT DEFINED ROBOTICSLAB-SPEECH_DATA_INSTALL_DIR)
Expand Down
5 changes: 0 additions & 5 deletions share/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@
# Author: Juan G Victores & Raul de santos Rico
# CopyPolicy: Released under the terms of the GNU GPL v2.0.

find_package(YARP REQUIRED)
list(APPEND CMAKE_MODULE_PATH ${YARP_MODULE_PATH})
include(YarpInstallationHelpers)
yarp_configure_external_installation(roboticslab-speech)

yarp_install(FILES ymanager.ini
DESTINATION ${ROBOTICSLAB-SPEECH_DATA_INSTALL_DIR})

Expand Down

0 comments on commit 74a68d0

Please sign in to comment.