-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create a 'targets' subdirectory to contain specialisations of the rtt…
…-config.h file. The OROCOS_TARGET define is now used to locate the target file. Also the library names and .pc files are extended with the -<target> suffix. This is all to support multiple targets in the same directory. If no target is specified, a default is used. git-svn-id: https://svn.mech.kuleuven.be/repos/orocos/trunk/rtt@28621 ce417995-dfc9-0310-95a0-acdaff106893
- Loading branch information
psoetens
committed
Oct 5, 2007
1 parent
d836bbc
commit ddf4b11
Showing
10 changed files
with
154 additions
and
93 deletions.
There are no files selected for viewing
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
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
|
||
GLOBAL_ADD_INCLUDE( rtt/targets rtt-target.h) | ||
GLOBAL_ADD_INCLUDE( rtt/targets ${OROCOS_TARGET}) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
The target files in this directory contain the defines which were | ||
enabled when the orocos-rtt-<target> library was built. You require | ||
these defines when including RTT headers in your application. | ||
|
||
One target file is included by rtt-target.h, which was included by | ||
rtt-config.h. Target files may be hand written or automatically be | ||
generated by the RTT build system and describe which features were on | ||
or off and which OS layer was selected. | ||
|
||
This directory structure allows to have multiple configurations | ||
(targets) share the same header files in the same location. The user | ||
can choose a configuration by setting -DOROCOS_TARGET=<target> where | ||
<target> is a filename in this directory, for example: | ||
|
||
-DOROCOS_TARGET=lxrt | ||
|
||
When the pkg-config tool is used to query for the --cflags, the | ||
-DOROCOS_TARGET option is automatically presented. In case no | ||
OROCOS_TARGET define is given, a default is selected. | ||
|
||
This system was introduced to ease packaging and installing for | ||
multiple targets on the same system, in the same directory structure. | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/** | ||
* This is a helper file in the targets subdirectory | ||
* It includes the correct target, on behalf of rtt-config.h | ||
*/ | ||
|
||
#define ORO_RTT_CONFIG_str(s) ORO_RTT_CONFIG__str(s) | ||
#define ORO_RTT_CONFIG__str(s) #s | ||
|
||
#define OROCOS_TARGET_HEADER ORO_RTT_CONFIG_str(OROCOS_TARGET) | ||
|
||
#include OROCOS_TARGET_HEADER | ||
|
||
#undef ORO_RTT_CONFIG_str | ||
#undef ORO_RTT_CONFIG__str |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
#ifndef RTT_TARGET_@OROCOS_TARGET@_H | ||
#define RTT_TARGET_@OROCOS_TARGET@_H | ||
|
||
#define OROCFG_CORELIB_REALTIME_TOOLKIT 1 | ||
#define OROCFG_CORELIB_REALTIME_TOOLKIT_IMPORT 1 | ||
|
||
#cmakedefine OS_AGNOSTIC | ||
#ifdef OS_AGNOSTIC | ||
#define OROBLD_OS_AGNOSTIC | ||
#endif | ||
#define ORONUM_OS_MAX_THREADS @OS_MAX_THREADS@ | ||
#define OROSEM_OS_PERIODIC_THREADS_MAX_OVERRUN 5 | ||
#define OROSEM_OS_LOCK_MEMORY 1 | ||
#cmakedefine OS_HAVE_MAIN | ||
#cmakedefine OS_HAVE_IOSTREAM | ||
#cmakedefine OS_HAVE_STREAMS | ||
#cmakedefine OS_THREAD_SCOPE | ||
#ifdef OS_THREAD_SCOPE | ||
#define OROPKG_OS_THREAD_SCOPE | ||
#endif | ||
|
||
#cmakedefine CONFIG_FORCE_UP | ||
|
||
#cmakedefine OS_EMBEDDED | ||
#ifdef OS_EMBEDDED | ||
#define ORO_EMBEDDED | ||
#endif | ||
|
||
#cmakedefine OS_NOEXCEPTIONS | ||
#ifdef OS_NOEXCEPTIONS | ||
#define ORO_OS_NOEXCEPTIONS | ||
#endif | ||
|
||
#if !defined(OS_EMBEDDED) || defined(OS_EMBEDDED_SCRIPTING) | ||
#define OROPKG_EXECUTION_PROGRAM_PARSER | ||
#endif | ||
|
||
#cmakedefine OROBLD_DISABLE_LOGGING | ||
#cmakedefine OROSEM_PRINTF_LOGGING | ||
#cmakedefine OROSEM_FILE_LOGGING | ||
#cmakedefine OROSEM_REMOTE_LOGGING | ||
#define ORONUM_LOGGING_BUFSIZE @ORONUM_LOGGING_BUFSIZE@ | ||
|
||
#define OROPKG_OS | ||
#define OROPKG_CORELIB_EVENTS | ||
#define OROPKG_CORELIB_REPORTING | ||
#define OROPKG_DEVICE_INTERFACE | ||
|
||
#define OROPKG_EXECUTION | ||
#define OROPKG_EXECUTION_ENGINE 1 | ||
#define OROPKG_EXECUTION_PROGRAM_PROCESSOR | ||
#cmakedefine OROPKG_EXECUTION_ENGINE_EVENTS | ||
#cmakedefine OROPKG_EXECUTION_ENGINE_COMMANDS | ||
#cmakedefine OROPKG_EXECUTION_ENGINE_PROGRAMS | ||
#cmakedefine OROPKG_EXECUTION_ENGINE_STATEMACHINES | ||
#define ORONUM_EXECUTION_PROC_QUEUE_SIZE @ORONUM_EXECUTION_PROC_QUEUE_SIZE@ | ||
|
||
#cmakedefine ORO_SUPPORT_BOOST | ||
|
||
/** If marshalling is enabled, use these defines. */ | ||
#cmakedefine ENABLE_MARSHALLING | ||
#ifdef ENABLE_MARSHALLING | ||
#cmakedefine OROPKG_SUPPORT_XERCES_C | ||
#define OROPKG_CORELIB_PROPERTIES_MARSHALLING | ||
#define OROPKG_CORELIB_PROPERTIES_MARSHALLING_CPF 1 | ||
#define ORODAT_CORELIB_PROPERTIES_MARSHALLING_INCLUDE @ORODAT_CORELIB_PROPERTIES_MARSHALLING_INCLUDE@ | ||
#define OROCLS_CORELIB_PROPERTIES_MARSHALLING_DRIVER @OROCLS_CORELIB_PROPERTIES_MARSHALLING_DRIVER@ | ||
#define ORODAT_CORELIB_PROPERTIES_DEMARSHALLING_INCLUDE @ORODAT_CORELIB_PROPERTIES_DEMARSHALLING_INCLUDE@ | ||
#define OROCLS_CORELIB_PROPERTIES_DEMARSHALLING_DRIVER @OROCLS_CORELIB_PROPERTIES_DEMARSHALLING_DRIVER@ | ||
#endif | ||
|
||
// Target detection macros for users: | ||
// Backwards compatibility: | ||
#define OROPKG_OS_@OROCOS_TARGET_CAP@ | ||
|
||
// New format: | ||
#define OROCOS_TARGET_@OROCOS_TARGET_CAP@ 1 | ||
|
||
// Safety check: | ||
#ifndef OROPKG_OS_@OROCOS_TARGET_CAP@ | ||
#error "Configuration error: OROPKG_OS_@OROCOS_TARGET_CAP@ not defined !" | ||
#endif | ||
|
||
#endif |