diff -ru a/RtMidi.cpp b/RtMidi.cpp --- a/RtMidi.cpp 2021-12-23 16:46:33.000000000 -0500 +++ b/RtMidi.cpp 2021-12-23 16:48:19.000000000 -0500 @@ -39,6 +39,9 @@ #include "RtMidi.h" #include +#if defined(__APPLE__) +#include +#endif #if defined(__MACOSX_CORE__) #if TARGET_OS_IPHONE