From: <sv...@op...> - 2024-08-17 14:13:09
|
Author: manx Date: Sat Aug 17 16:12:58 2024 New Revision: 21504 URL: https://source.openmpt.org/browse/openmpt/?op=revision&rev=21504 Log: Merged revision(s) 21502-21503 from trunk/OpenMPT: [Fix] MinGW32 runtime headers require __off64_t when including some C and/or C++ stdlib headers. This is declared in <sys/types.h>, which however is not included in some header chains. Forcibly include it in openmpt/all/BuildSettings.hpp. See r17412. ........ [Fix] MinGW32 runtime headers require __off64_t when including some C and/or C++ stdlib headers. This is declared in <sys/types.h>, which however is not included in some header chains. Forcibly include it in openmpt/all/BuildSettings.hpp. See r17412. ........ Modified: branches/OpenMPT-1.31/ (props changed) branches/OpenMPT-1.31/common/stdafx.h branches/OpenMPT-1.31/src/mpt/base/detect_quirks.hpp branches/OpenMPT-1.31/src/openmpt/all/BuildSettings.hpp Modified: branches/OpenMPT-1.31/common/stdafx.h ============================================================================== --- branches/OpenMPT-1.31/common/stdafx.h Sat Aug 17 16:09:56 2024 (r21503) +++ branches/OpenMPT-1.31/common/stdafx.h Sat Aug 17 16:12:58 2024 (r21504) @@ -16,11 +16,6 @@ #include "openmpt/all/BuildSettings.hpp" -#if defined(__MINGW32__) && !defined(__MINGW64__) -#include <sys/types.h> -#endif - - #if defined(MODPLUG_TRACKER) #if defined(MPT_WITH_MFC) Modified: branches/OpenMPT-1.31/src/mpt/base/detect_quirks.hpp ============================================================================== --- branches/OpenMPT-1.31/src/mpt/base/detect_quirks.hpp Sat Aug 17 16:09:56 2024 (r21503) +++ branches/OpenMPT-1.31/src/mpt/base/detect_quirks.hpp Sat Aug 17 16:12:58 2024 (r21504) @@ -235,6 +235,16 @@ +#if MPT_LIBC_MINGW +// MinGW32 runtime headers require __off64_t when including some C and/or C++ stdlib headers. +// This is declared in <sys/types.h>, which howeger is not included in some header chains. +#if (defined(__MINGW32__) && !defined(__MINGW64__)) +#define MPT_LIBC_QUIRK_REQUIRES_SYS_TYPES_H +#endif +#endif + + + #if MPT_LIBC_DJGPP #define MPT_LIBC_QUIRK_NO_FENV #endif Modified: branches/OpenMPT-1.31/src/openmpt/all/BuildSettings.hpp ============================================================================== --- branches/OpenMPT-1.31/src/openmpt/all/BuildSettings.hpp Sat Aug 17 16:09:56 2024 (r21503) +++ branches/OpenMPT-1.31/src/openmpt/all/BuildSettings.hpp Sat Aug 17 16:12:58 2024 (r21504) @@ -61,3 +61,11 @@ #endif + + + +// immediate quirk fixups + +#if defined(MPT_LIBC_QUIRK_REQUIRES_SYS_TYPES_H) +#include <sys/types.h> +#endif |