#ifndef lib_defs_h #define lib_defs_h /* Cesar project {{{ * * Copyright (C) 2007 Spidcom * * <<>> * * }}} */ /** * \file lib/defs.h * \brief Globals compiler and target specific defines. * \ingroup lib */ /** Defined to 1 if the target is using big endian. */ #define DEFS_BIG_ENDIAN _see_below_ #undef DEFS_BIG_ENDIAN /** Defined to 1 if structure's bit fields should be reversed. */ #define DEFS_REVERSE_BITFIELDS _see_below_ #undef DEFS_REVERSE_BITFIELDS #if defined (__sparc__) # define DEFS_BIG_ENDIAN 1 # define DEFS_REVERSE_BITFIELDS 1 #else /* others. */ # define DEFS_BIG_ENDIAN 0 # define DEFS_REVERSE_BITFIELDS 0 #endif /** Declare a name as private. It will define a static symbol unless * NO_PRIVATE is defined. */ #ifndef NO_PRIVATE # define PRIVATE static #else # define PRIVATE #endif #if __GNUC__ < 4 /* This attribute is not defined for older GCC versions. */ # define warn_unused_result #endif #if ((__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)) \ && defined (__NO_INLINE__)) /* We really really want inlining. GCC 4.4 will not inline if optimization is * disable. */ # define inline inline __attribute__ ((always_inline)) #endif #endif /* lib_defs_h */