From 7c3f83215afbb4389473acffe55b99c15bfe757c Mon Sep 17 00:00:00 2001 From: Jason2866 <24528715+Jason2866@users.noreply.github.com> Date: Thu, 17 Oct 2024 21:58:48 +0200 Subject: [PATCH] switch off midi for esp32 -> esp32 Compiler bug --- lib/lib_audio/ESP8266Audio/src/AudioGeneratorMIDI.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/lib_audio/ESP8266Audio/src/AudioGeneratorMIDI.h b/lib/lib_audio/ESP8266Audio/src/AudioGeneratorMIDI.h index 8a1ac3f9a..79377c47e 100644 --- a/lib/lib_audio/ESP8266Audio/src/AudioGeneratorMIDI.h +++ b/lib/lib_audio/ESP8266Audio/src/AudioGeneratorMIDI.h @@ -21,6 +21,10 @@ #ifndef _AUDIOGENERATORMIDI_H #define _AUDIOGENERATORMIDI_H +#if defined(ESP32) && (__GNUC__ >= 8) && (__XTENSA__) +// Do not build, Espressif's GCC8+ has a compiler bug +#else // __GNUC__ == 8 + #include "AudioGenerator.h" #define TSF_NO_STDIO @@ -90,7 +94,7 @@ class AudioGeneratorMIDI : public AudioGenerator unsigned long earliest_time = 0; struct tonegen_status { /* current status of a tone generator */ - bool playing; /* is it playing? */ + bool playing; /* is it playing? */ char track; /* if so, which track is the note from? */ char note; /* what note is playing? */ char instrument; /* what instrument? */ @@ -176,6 +180,7 @@ class AudioGeneratorMIDI : public AudioGenerator short samplesRendered[256]; }; +#endif //__GNUC__ == 8 #endif