From: <sv...@op...> - 2024-08-12 16:09:40
|
Author: manx Date: Mon Aug 12 18:09:28 2024 New Revision: 21398 URL: https://source.openmpt.org/browse/openmpt/?op=revision&rev=21398 Log: [Ref] mpt/base/detect_compiler.hpp: Add MPT_COMPILER_QUIRK_APPLE_CLANG. Modified: trunk/OpenMPT/soundlib/SampleFormatMP3.cpp trunk/OpenMPT/src/mpt/base/detect_compiler.hpp Modified: trunk/OpenMPT/soundlib/SampleFormatMP3.cpp ============================================================================== --- trunk/OpenMPT/soundlib/SampleFormatMP3.cpp Mon Aug 12 18:08:37 2024 (r21397) +++ trunk/OpenMPT/soundlib/SampleFormatMP3.cpp Mon Aug 12 18:09:28 2024 (r21398) @@ -219,7 +219,7 @@ #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wframe-larger-than=16000" #endif // MPT_COMPILER_GCC -#if (MPT_CLANG_AT_LEAST(13,0,0) && !MPT_OS_MACOSX_OR_IOS) || MPT_CLANG_AT_LEAST(13,1,0) +#if (MPT_CLANG_AT_LEAST(13,0,0) && !defined(MPT_COMPILER_QUIRK_APPLE_CLANG)) || MPT_CLANG_AT_LEAST(13,1,0) #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wframe-larger-than" #endif // MPT_COMPILER_CLANG @@ -227,7 +227,7 @@ { return mp3dec_decode_frame(dec, mp3, mp3_bytes, pcm, info); } -#if (MPT_CLANG_AT_LEAST(13,0,0) && !MPT_OS_MACOSX_OR_IOS) || MPT_CLANG_AT_LEAST(13,1,0) +#if (MPT_CLANG_AT_LEAST(13,0,0) && !defined(MPT_COMPILER_QUIRK_APPLE_CLANG)) || MPT_CLANG_AT_LEAST(13,1,0) #pragma clang diagnostic pop #endif // MPT_COMPILER_CLANG #if MPT_COMPILER_GCC Modified: trunk/OpenMPT/src/mpt/base/detect_compiler.hpp ============================================================================== --- trunk/OpenMPT/src/mpt/base/detect_compiler.hpp Mon Aug 12 18:08:37 2024 (r21397) +++ trunk/OpenMPT/src/mpt/base/detect_compiler.hpp Mon Aug 12 18:09:28 2024 (r21398) @@ -217,6 +217,16 @@ +// detect compiler quirks + +#if MPT_COMPILER_CLANG +#if defined(__APPLE__) +#define MPT_COMPILER_QUIRK_APPLE_CLANG +#endif +#endif + + + // detect compiler setting quirks #if MPT_COMPILER_GCC |