https://github.com/ZDoom/ZMusic/pull/45 From 9a72e0f09558d5b047fa7f2a6ee59e10a959333b Mon Sep 17 00:00:00 2001 From: Sam James Date: Sat, 4 Feb 2023 20:16:24 +0000 Subject: [PATCH] Add missing standard library includes (fix build with GCC 13) GCC 13 (as usual for new compiler releases) shuffles around some internal includes and so etc is no longer transitively included. See https://www.gnu.org/software/gcc/gcc-13/porting_to.html. Bug: https://bugs.gentoo.org/892814 --- a/source/mididevices/music_adlmidi_mididevice.cpp +++ b/source/mididevices/music_adlmidi_mididevice.cpp @@ -34,6 +34,7 @@ // HEADER FILES ------------------------------------------------------------ +#include #include #include "zmusic/zmusic_internal.h" --- a/source/mididevices/music_fluidsynth_mididevice.cpp +++ b/source/mididevices/music_fluidsynth_mididevice.cpp @@ -35,6 +35,7 @@ // HEADER FILES ------------------------------------------------------------ #include +#include #include #include #include "zmusic/zmusic_internal.h" --- a/source/mididevices/music_opl_mididevice.cpp +++ b/source/mididevices/music_opl_mididevice.cpp @@ -35,6 +35,7 @@ // HEADER FILES ------------------------------------------------------------ +#include #include "zmusic/zmusic_internal.h" #include "mididevice.h" #include "zmusic/mus2midi.h" @@ -333,4 +334,4 @@ MIDIDevice* CreateOplMIDIDevice(const char* Args) { throw std::runtime_error("OPL device not supported in this configuration"); } -#endif \ No newline at end of file +#endif --- a/source/mididevices/music_opnmidi_mididevice.cpp +++ b/source/mididevices/music_opnmidi_mididevice.cpp @@ -34,6 +34,7 @@ // HEADER FILES ------------------------------------------------------------ +#include #include "mididevice.h" #include "zmusic/zmusic_internal.h" --- a/source/mididevices/music_timidity_mididevice.cpp +++ b/source/mididevices/music_timidity_mididevice.cpp @@ -34,6 +34,7 @@ // HEADER FILES ------------------------------------------------------------ +#include #include #include "mididevice.h" #include "zmusic/zmusic_internal.h" --- a/source/mididevices/music_timiditypp_mididevice.cpp +++ b/source/mididevices/music_timiditypp_mididevice.cpp @@ -32,6 +32,7 @@ ** */ +#include #include "mididevice.h" #include "zmusic/zmusic_internal.h" @@ -239,4 +240,4 @@ MIDIDevice* CreateTimidityPPMIDIDevice(const char* Args, int samplerate) { throw std::runtime_error("Timidity++ device not supported in this configuration"); } -#endif \ No newline at end of file +#endif --- a/source/mididevices/music_wavewriter_mididevice.cpp +++ b/source/mididevices/music_wavewriter_mididevice.cpp @@ -38,6 +38,7 @@ #include "mididevice.h" #include "zmusic/m_swap.h" #include "fileio.h" +#include #include // MACROS ------------------------------------------------------------------ --- a/source/mididevices/music_wildmidi_mididevice.cpp +++ b/source/mididevices/music_wildmidi_mididevice.cpp @@ -34,6 +34,7 @@ // HEADER FILES ------------------------------------------------------------ +#include #include "mididevice.h" #include "zmusic/zmusic_internal.h" @@ -278,4 +279,4 @@ MIDIDevice* CreateWildMIDIDevice(const char* Args, int samplerate) { throw std::runtime_error("WildMidi device not supported in this configuration"); } -#endif \ No newline at end of file +#endif --- a/source/musicformats/music_midi.cpp +++ b/source/musicformats/music_midi.cpp @@ -34,8 +34,9 @@ // HEADER FILES ------------------------------------------------------------ -#include #include +#include +#include #include #include "zmusic/zmusic_internal.h" #include "zmusic/musinfo.h" --- a/source/streamsources/music_gme.cpp +++ b/source/streamsources/music_gme.cpp @@ -38,9 +38,11 @@ //#define GME_DLL #include +#include +#include + #include "streamsource.h" #include -#include #include "fileio.h" // MACROS ------------------------------------------------------------------ --- a/source/streamsources/music_opl.cpp +++ b/source/streamsources/music_opl.cpp @@ -35,6 +35,8 @@ #ifdef HAVE_OPL +#include + #include "streamsource.h" #include "oplsynth/opl.h" #include "oplsynth/opl_mus_player.h" --- a/source/zmusic/fileio.h +++ b/source/zmusic/fileio.h @@ -25,6 +25,7 @@ #pragma once #include #include +#include #include #include -- 2.39.1