The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

172 lines
5.2KB

  1. /*
  2. ==============================================================================
  3. This file is part of the JUCE library - "Jules' Utility Class Extensions"
  4. Copyright 2004-11 by Raw Material Software Ltd.
  5. ------------------------------------------------------------------------------
  6. JUCE can be redistributed and/or modified under the terms of the GNU General
  7. Public License (Version 2), as published by the Free Software Foundation.
  8. A copy of the license is included in the JUCE distribution, or can be found
  9. online at www.gnu.org/licenses.
  10. JUCE is distributed in the hope that it will be useful, but WITHOUT ANY
  11. WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
  12. A PARTICULAR PURPOSE. See the GNU General Public License for more details.
  13. ------------------------------------------------------------------------------
  14. To release a closed-source product which uses JUCE, commercial licenses are
  15. available: visit www.rawmaterialsoftware.com/juce for more information.
  16. ==============================================================================
  17. */
  18. #ifndef __JUCE_STANDARDHEADER_JUCEHEADER__
  19. #define __JUCE_STANDARDHEADER_JUCEHEADER__
  20. //==============================================================================
  21. /** Current JUCE version number.
  22. See also SystemStats::getJUCEVersion() for a string version.
  23. */
  24. #define JUCE_MAJOR_VERSION 2
  25. #define JUCE_MINOR_VERSION 0
  26. #define JUCE_BUILDNUMBER 27
  27. /** Current Juce version number.
  28. Bits 16 to 32 = major version.
  29. Bits 8 to 16 = minor version.
  30. Bits 0 to 8 = point release.
  31. See also SystemStats::getJUCEVersion() for a string version.
  32. */
  33. #define JUCE_VERSION ((JUCE_MAJOR_VERSION << 16) + (JUCE_MINOR_VERSION << 8) + JUCE_BUILDNUMBER)
  34. //==============================================================================
  35. #include "juce_TargetPlatform.h" // (sets up the various JUCE_WINDOWS, JUCE_MAC, etc flags)
  36. #include "juce_PlatformDefs.h"
  37. //==============================================================================
  38. // Now we'll include some common OS headers..
  39. #if JUCE_MSVC
  40. #pragma warning (push)
  41. #pragma warning (disable: 4514 4245 4100)
  42. #endif
  43. #include <cstdlib>
  44. #include <cstdarg>
  45. #include <climits>
  46. #include <limits>
  47. #include <cmath>
  48. #include <cwchar>
  49. #include <stdexcept>
  50. #include <typeinfo>
  51. #include <cstring>
  52. #include <cstdio>
  53. #include <iostream>
  54. #include <vector>
  55. #if JUCE_USE_INTRINSICS
  56. #include <intrin.h>
  57. #endif
  58. #if JUCE_MAC || JUCE_IOS
  59. #include <libkern/OSAtomic.h>
  60. #endif
  61. #if JUCE_LINUX
  62. #include <signal.h>
  63. #if __INTEL_COMPILER
  64. #if __ia64__
  65. #include <ia64intrin.h>
  66. #else
  67. #include <ia32intrin.h>
  68. #endif
  69. #endif
  70. #endif
  71. #if JUCE_MSVC && JUCE_DEBUG
  72. #include <crtdbg.h>
  73. #endif
  74. #if JUCE_MSVC
  75. #pragma warning (pop)
  76. #endif
  77. #if JUCE_ANDROID
  78. #include <sys/atomics.h>
  79. #include <byteswap.h>
  80. #endif
  81. // undef symbols that are sometimes set by misguided 3rd-party headers..
  82. #undef check
  83. #undef TYPE_BOOL
  84. #undef max
  85. #undef min
  86. //==============================================================================
  87. // DLL building settings on Windows
  88. #if JUCE_MSVC
  89. #ifdef JUCE_DLL_BUILD
  90. #define JUCE_API __declspec (dllexport)
  91. #pragma warning (disable: 4251)
  92. #elif defined (JUCE_DLL)
  93. #define JUCE_API __declspec (dllimport)
  94. #pragma warning (disable: 4251)
  95. #endif
  96. #ifdef __INTEL_COMPILER
  97. #pragma warning (disable: 1125) // (virtual override warning)
  98. #endif
  99. #elif defined (JUCE_DLL) || defined (JUCE_DLL_BUILD)
  100. #define JUCE_API __attribute__ ((visibility("default")))
  101. #endif
  102. //==============================================================================
  103. #ifndef JUCE_API
  104. #define JUCE_API /**< This macro is added to all juce public class declarations. */
  105. #endif
  106. #if JUCE_MSVC && JUCE_DLL_BUILD
  107. #define JUCE_PUBLIC_IN_DLL_BUILD(declaration) public: declaration; private:
  108. #else
  109. #define JUCE_PUBLIC_IN_DLL_BUILD(declaration) declaration;
  110. #endif
  111. /** This macro is added to all juce public function declarations. */
  112. #define JUCE_PUBLIC_FUNCTION JUCE_API JUCE_CALLTYPE
  113. #if (! defined (JUCE_CATCH_DEPRECATED_CODE_MISUSE)) && JUCE_DEBUG && ! DOXYGEN
  114. /** This turns on some non-essential bits of code that should prevent old code from compiling
  115. in cases where method signatures have changed, etc.
  116. */
  117. #define JUCE_CATCH_DEPRECATED_CODE_MISUSE 1
  118. #endif
  119. #ifndef DOXYGEN
  120. #define JUCE_NAMESPACE juce // This old macro is deprecated: you should just use the juce namespace directly.
  121. #endif
  122. //==============================================================================
  123. // Now include some common headers...
  124. namespace juce
  125. {
  126. extern JUCE_API bool JUCE_CALLTYPE juce_isRunningUnderDebugger();
  127. #if JUCE_LOG_ASSERTIONS
  128. extern JUCE_API void logAssertion (const char* file, int line) noexcept;
  129. #endif
  130. #include "../memory/juce_Memory.h"
  131. #include "../maths/juce_MathsFunctions.h"
  132. #include "../memory/juce_ByteOrder.h"
  133. #include "../logging/juce_Logger.h"
  134. #include "../memory/juce_LeakedObjectDetector.h"
  135. }
  136. #endif // __JUCE_STANDARDHEADER_JUCEHEADER__