tinysip_config.h 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. /*
  2. * Copyright (C) 2010-2011 Mamadou Diop.
  3. *
  4. * Contact: Mamadou Diop <diopmamadou(at)doubango[dot]org>
  5. *
  6. * This file is part of Open Source Doubango Framework.
  7. *
  8. * DOUBANGO is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * DOUBANGO is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with DOUBANGO.
  20. *
  21. */
  22. #ifndef TINYSIP_CONFIG_H
  23. #define TINYSIP_CONFIG_H
  24. #ifdef __SYMBIAN32__
  25. #undef _WIN32 /* Because of WINSCW */
  26. #endif
  27. /* Windows (XP/Vista/7/CE and Windows Mobile) macro definition */
  28. #if defined(WIN32)|| defined(_WIN32) || defined(_WIN32_WCE)
  29. # define TSIP_UNDER_WINDOWS 1
  30. #elif __APPLE__
  31. # define TSIP_UNDER_APPLE 1
  32. #endif
  33. // Windows (XP/Vista/7/CE and Windows Mobile) macro definition
  34. #if defined(WIN32)|| defined(_WIN32) || defined(_WIN32_WCE)
  35. # define TSIP_UNDER_WINDOWS 1
  36. # if defined(WINAPI_FAMILY) && (WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP || WINAPI_FAMILY == WINAPI_FAMILY_APP)
  37. # define TSIP_UNDER_WINDOWS_RT 1
  38. # endif
  39. #elif __APPLE__
  40. # define TSIP_UNDER_APPLE 1
  41. #endif
  42. #if !defined(__GNUC__) && defined(TINYSIP_EXPORTS)
  43. # define TINYSIP_API __declspec(dllexport)
  44. # define TINYSIP_GEXTERN extern __declspec(dllexport)
  45. #elif !defined(__GNUC__) && !defined(TINYSIP_IMPORTS_IGNORE)
  46. # define TINYSIP_API __declspec(dllimport)
  47. # define TINYSIP_GEXTERN __declspec(dllimport)
  48. #else
  49. # define TINYSIP_API
  50. # define TINYSIP_GEXTERN extern
  51. #endif
  52. /* Guards against C++ name mangling */
  53. #ifdef __cplusplus
  54. # define TSIP_BEGIN_DECLS extern "C" {
  55. # define TSIP_END_DECLS }
  56. #else
  57. # define TSIP_BEGIN_DECLS
  58. # define TSIP_END_DECLS
  59. #endif
  60. /* Disable some well-known warnings */
  61. #ifdef _MSC_VER
  62. # define _CRT_SECURE_NO_WARNINGS
  63. #endif
  64. /* Detecting C99 compilers */
  65. #if (__STDC_VERSION__ == 199901L) && !defined(__C99__)
  66. # define __C99__
  67. #endif
  68. /* Whether to use SIP Compact headers (RFC 3261 - 7.3.3 Compact Form) */
  69. #if !defined(TSIP_COMPACT_HEADERS)
  70. # define TSIP_COMPACT_HEADERS 0
  71. #endif
  72. #include <stdint.h>
  73. #ifdef __SYMBIAN32__
  74. #include <stdlib.h>
  75. #endif
  76. #if defined(__APPLE__)
  77. # include <TargetConditionals.h>
  78. #endif
  79. #if HAVE_CONFIG_H
  80. #include <config.h>
  81. #endif
  82. #endif // TINYSIP_CONFIG_H