-
Notifications
You must be signed in to change notification settings - Fork 80
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
useorocos: add separate configuration macros independent of installation #306
Open
meyerj
wants to merge
8
commits into
master
Choose a base branch
from
master-useorocos-separate-configuration-from-installation
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
useorocos: add separate configuration macros independent of installation #306
meyerj
wants to merge
8
commits into
master
from
master-useorocos-separate-configuration-from-installation
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…in UseOROCOS-RTT Suspect that this is a left-over copy/paste relic from the original work, which used orocos_executable() as a beginning (which does use this variable).
…th unsupported build scenario
Ensure the the library-related "orocos_xxx()" macros all follow the same structure and ordering. There should be not net change in semantics from this.
…table Using orocos_executable() results in an executable that *is* suffixed with the OROCOS target, but using orocos_configure_executable() results in an executable that is *not* suffixed with the OROCOS target. To reduce confusion standardize so that calling either function results in an executable that *is* suffixed with the OROCOS target.
Add orocos_configure_xxx() macros for each of component libraries, utility libraries, typekits, and plugins. This moves the responsibility for the ADD_LIBRARY() and INSTALL() calls to the application, instead of OROCOS.
…-RTT Add a "NO_TARGET_SUFFIX" option to the orocos_xxx() and orocos_configure_xxx() marcos - e.g. orocos_library(), orocos_configure_library() - that does *not* add the OROCOS target as a suffix to the binary (e.g. with NO_TARGET_SUFFIX set "libxxx-gnulinux.so" becomes "libxxx.so" instead). Applies to all binaries - component library - utility library - executable - typekit - plugin
...to avoid duplicated CMake code. Other small changes: - Add option QUIET to most macros to suppress the informational message output, required to reduce verbosity for internal calls. - Rename internal argument prefix ADD_COMPONENT to ORO_COMPONENT for consistency. - Remove comment "For ros builds, the version number is ignored.". Not sure why this should be the case. The target property is also set in rosbuild mode. - Add exported target dependencies in orocos_configure_xxx() macros consistently (#244).
…the full macros The installation directory (AC_INSTALL_DIR) is unknown in the orocos_configure_xxx() macros because installation is handled by the user. All the *_EXPORTED_* variables are only needed to find the libraries and include directories of one package when using orocos_find_package() or orocos_use_package() in another package that is built within the same build-space, e.g. when using catkin_make. In all other cases the libraries and their paths are written to and loaded from the pkg-config (.pc) files, either in the devel-space (for isolated builds without installation, e.g. catkin_make_isolated or catkin_tools) or installed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This patch adds separate CMake macros to UseOROCOS-RTT.cmake to configure existing targets (component and plugin libraries) for Orocos independent of their creation and installation. Most work has been done by @snrkiwi.
orocos_configure_xxx(TARGET ...)
The configuration of a target for Orocos applies the following changes to the given target:
-gnulinux
) to the library output name unless disabled by the macro flagNO_TARGET_SUFFIX
(cmake property OUTPUT_NAME)COMPONENT_VERSION
is set orVERSION
is passed as a macro argument (cmake property VERSION)ComponentLoader
andPluginLoader
(cmake property LIBRARY_OUTPUT_DIRECTORY)RTT_COMPONENT
(for component libraries only)OROCOS-RTT_LIBRARIES
)orocos_use_package()
before. In catkin build mode (ORO_USE_CATKIN
is true) the macro is implicitly called for all Orocos packages listed as build dependencies inpackage.xml
. UnlessOROCOS_NO_AUTO_LINKING
is set, also link to all Orocos library targets.OROCOS_DEFINED_<COMPS|LIBS|TYPES|PLUGINS>
needed for the generation of pkg-config (.pc) files inorocos_generate_package()
.orocos_xxx(TARGET SOURCES ...)
Everything else is only done by the full macros. The behavior of those macros should not have been changed by this patch.
CMAKE_INSTALL_PREFIX
catkin_make
), where the generated pkg-config files cannot be used yet.orocos_configure_xxx()
macro mentioned above.New options for all macros
NO_TARGET_SUFFIX
: do not append the Orocos target to the library and executable names (not required for single target installations)QUIET
: suppress the informational output of the macros