etl_config.h 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. #ifndef __ETL_CONFIG_H
  2. #define __ETL_CONFIG_H
  3. #include "etl_profile.h"
  4. #include <utility>
  5. #ifndef ETL_NAMESPACE
  6. # define ETL_NAMESPACE etl
  7. #endif
  8. #define ETL_DIRECTORY_SEPARATORS "/\\"
  9. #define ETL_DIRECTORY_SEPARATOR0 '/'
  10. #define ETL_DIRECTORY_SEPARATOR1 '\\'
  11. // #ifdef WIN32
  12. // #define ETL_DIRECTORY_SEPARATOR ETL_DIRECTORY_SEPARATOR1
  13. #define ETL_DIRECTORY_SEPARATOR ETL_DIRECTORY_SEPARATOR0
  14. #ifndef ETL_FLAG_NONAMESPACE
  15. # define _ETL ETL_NAMESPACE
  16. # define _ETL_BEGIN_NAMESPACE namespace _ETL {
  17. # define _ETL_END_NAMESPACE };
  18. # define _STD_BEGIN_NAMESPACE namespace std {
  19. # define _STD_END_NAMESPACE };
  20. #else
  21. # define _ETL
  22. # define _ETL_BEGIN_NAMESPACE
  23. # define _ETL_END_NAMESPACE
  24. # define _STD_BEGIN_NAMESPACE
  25. # define _STD_END_NAMESPACE
  26. #endif
  27. #define _ETL_BEGIN_CDECLS extern "C" {
  28. #define _ETL_END_CDECLS }
  29. #ifdef _REENTRANT
  30. #define ETL_REENTRANT 1
  31. #endif
  32. /* If __FUNC__ is not defined,
  33. ** try to define it. If we cannot,
  34. ** then just leave it undefined.
  35. */
  36. #ifndef __FUNC__
  37. /*
  38. * # if defined __cplusplus ? __GNUC_PREREQ (2, 6) : __GNUC_PREREQ (2, 4)
  39. # define __FUNC__ __PRETTY_FUNCTION__
  40. # else
  41. # if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
  42. # define __FUNC__ __func__
  43. # endif
  44. # endif
  45. */
  46. #endif
  47. #ifdef __GNUG__
  48. #define ETL_DEPRECATED_FUNCTION __attribute__ ((deprecated))
  49. #else
  50. #define ETL_DEPRECATED_FUNCTION
  51. #endif
  52. #ifndef NULL
  53. #define NULL 0
  54. #endif
  55. #endif