Orocos Real-Time Toolkit  2.5.0
rtt-config.h
00001 #ifndef RTT_CONFIG_H
00002 #define RTT_CONFIG_H
00003 
00004 #define RTT_VERSION       2.5.0
00005 #define RTT_VERSION_MAJOR 2
00006 #define RTT_VERSION_MINOR 5
00007 #define RTT_VERSION_PATCH 0
00008 
00009 // if not defined, show an error
00010 #ifndef OROCOS_TARGET
00011 // OROCOS_TARGET is only used to include the file targets/OROCOS_TARGET
00012 #error "You _must_ define OROCOS_TARGET to an installed target (for example: -DOROCOS_TARGET=gnulinux )"
00013 #endif
00014 
00015 #include "os/targets/rtt-target.h"
00016 
00017 // Detect the CPU we are compiling for
00018 #if defined( __GNUC__ )
00019 #define OROBLD_GCC_VERSION (__GNUC__ * 10000 \
00020                              + __GNUC_MINOR__ * 100 \
00021                  + __GNUC_PATCHLEVEL__)
00022 #endif
00023 # if defined( __GNUC__ ) && defined( __i386__ )
00024 #  define OROBLD_OS_ARCH_i386
00025 # elif defined( __GNUC__ ) && defined( __x86_64__ )
00026 #  define OROBLD_OS_ARCH_x86_64
00027 # elif defined( __GNUC__ ) && (defined( __powerpc__ ) || defined( __PPC__ ) )
00028 #  define OROBLD_OS_ARCH_ppc
00029 # elif defined( __GNUC__ ) && (defined( __arm__ ) || defined( __ARM__ ) )
00030 #  define OROBLD_OS_ARCH_arm
00031 # elif defined( __GNUC__ ) && defined( __ia64__ )
00032 #  error "ia64 Is not yet supported, contact the orocos-dev mailinglist for further actions."
00033 #  define OROBLD_OS_ARCH_ia64
00034 # elif defined( __MINGW32__ ) && defined( __i386__ )
00035 #  define OROBLD_OS_ARCH_i386
00036 # elif defined( WIN32 )
00037 #  define OROBLD_OS_ARCH_i386
00038 # else
00039 #  error "Unknown Processor Architecture"
00040 #  define OROBLD_OS_ARCH_unknown
00041 # endif
00042 
00043 
00044 //
00045 // See: <http://gcc.gnu.org/wiki/Visibility>
00046 //
00047 #define RTT_GCC_HASVISIBILITY
00048 #if defined(__GNUG__) && defined(RTT_GCC_HASVISIBILITY) && (defined(__unix__) || defined(__APPLE__))
00049 
00050 # if defined(RTT_DLL_EXPORT)
00051    // Use RTT_API for normal function exporting
00052 #  define RTT_API    __attribute__((visibility("default")))
00053 
00054    // Use RTT_EXPORT for static template class member variables
00055    // They must always be 'globally' visible.
00056 #  define RTT_EXPORT __attribute__((visibility("default")))
00057 
00058    // Use RTT_HIDE to explicitly hide a symbol
00059 #  define RTT_HIDE   __attribute__((visibility("hidden")))
00060 
00061 # else
00062 #  define RTT_API
00063 #  define RTT_EXPORT __attribute__((visibility("default")))
00064 #  define RTT_HIDE   __attribute__((visibility("hidden")))
00065 # endif
00066 #else
00067    // Win32 and NOT GNU
00068 # if defined( WIN32 ) && !defined ( __MINGW32__ )
00069 #  if defined(RTT_DLL_EXPORT)
00070 #   define RTT_API    __declspec(dllexport)
00071 #   define RTT_EXPORT __declspec(dllexport)
00072 #   define RTT_HIDE   
00073 #  else
00074 #   define RTT_API   __declspec(dllimport)
00075 #   define RTT_EXPORT __declspec(dllexport)
00076 #   define RTT_HIDE 
00077 #  endif
00078 # else
00079 #  define RTT_API
00080 #  define RTT_EXPORT
00081 #  define RTT_HIDE
00082 # endif
00083 #endif
00084 
00085 #endif