Skip to content

Commit 9ffb8a5

Browse files
Do not compile AudioGeneratorMIDI if GCC is 8 (compiler bug) (#502)
1 parent 8b4010b commit 9ffb8a5

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

src/AudioGeneratorMIDI.cpp

+6
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@
5858

5959
#include "AudioGeneratorMIDI.h"
6060

61+
#if __GNUC__ == 8
62+
// Do not build, GCC8 has a compiler bug
63+
#else // __GNUC__ == 8
64+
6165
#pragma GCC optimize ("O3")
6266

6367
#define TSF_NO_STDIO
@@ -637,3 +641,5 @@ void AudioGeneratorMIDI::MakeStreamFromAFS(AudioFileSource *src, tsf_stream *afs
637641
afs->size = &afs_size;
638642
}
639643

644+
#endif //__GNUC__ == 8
645+

src/AudioGeneratorMIDI.h

+5
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
#ifndef _AUDIOGENERATORMIDI_H
2222
#define _AUDIOGENERATORMIDI_H
2323

24+
#if __GNUC__ == 8
25+
// Do not build, GCC8 has a compiler bug
26+
#else // __GNUC__ == 8
27+
2428
#include "AudioGenerator.h"
2529

2630
#define TSF_NO_STDIO
@@ -176,6 +180,7 @@ class AudioGeneratorMIDI : public AudioGenerator
176180
short samplesRendered[256];
177181
};
178182

183+
#endif //__GNUC__ == 8
179184

180185
#endif
181186

0 commit comments

Comments
 (0)