diff --git a/extras/Projucer/Source/Project/jucer_Module.cpp b/extras/Projucer/Source/Project/jucer_Module.cpp index 8383f46e43..cf8624c8de 100644 --- a/extras/Projucer/Source/Project/jucer_Module.cpp +++ b/extras/Projucer/Source/Project/jucer_Module.cpp @@ -328,7 +328,7 @@ void LibraryModule::addSettingsForModuleToExporter (ProjectExporter& exporter, P XCodeProjectExporter& xcodeExporter = dynamic_cast (exporter); if (project.isAUPluginHost()) - xcodeExporter.xcodeFrameworks.addTokens ("AudioUnit CoreAudioKit", false); + xcodeExporter.xcodeFrameworks.addTokens (xcodeExporter.isOSX() ? "AudioUnit CoreAudioKit" : "CoreAudioKit", false); const String frameworks (moduleInfo.moduleInfo [xcodeExporter.isOSX() ? "OSXFrameworks" : "iOSFrameworks"].toString()); xcodeExporter.xcodeFrameworks.addTokens (frameworks, ", ", StringRef()); diff --git a/modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp b/modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp index 36e75e9d59..c908d5fc55 100644 --- a/modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp +++ b/modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp @@ -65,11 +65,11 @@ void AudioPluginFormatManager::addDefaultFormats() // you should only call this method once! for (int i = formats.size(); --i >= 0;) { - #if JUCE_PLUGINHOST_VST + #if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX) jassert (dynamic_cast (formats[i]) == nullptr); #endif - #if JUCE_PLUGINHOST_VST3 + #if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN) jassert (dynamic_cast (formats[i]) == nullptr); #endif @@ -87,11 +87,11 @@ void AudioPluginFormatManager::addDefaultFormats() formats.add (new AudioUnitPluginFormat()); #endif - #if JUCE_PLUGINHOST_VST + #if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX) formats.add (new VSTPluginFormat()); #endif - #if JUCE_PLUGINHOST_VST3 + #if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN) formats.add (new VST3PluginFormat()); #endif diff --git a/modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm b/modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm index fec2a7988c..f865ea30c7 100644 --- a/modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm +++ b/modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm @@ -39,6 +39,18 @@ #include #endif +#ifndef JUCE_SUPPORTS_AUv3 + #if JUCE_COMPILER_SUPPORTS_VARIADIC_TEMPLATES && defined (MAC_OS_X_VERSION_MIN_REQUIRED) && (MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_8) && __OBJC2__ + #define JUCE_SUPPORTS_AUv3 1 + #else + #define JUCE_SUPPORTS_AUv3 0 + #endif +#endif + +#if JUCE_SUPPORTS_AUv3 + #include +#endif + namespace juce { @@ -61,14 +73,6 @@ namespace juce #define JUCE_AU_LOG(a) #endif -#ifndef JUCE_SUPPORTS_AUv3 - #if JUCE_COMPILER_SUPPORTS_VARIADIC_TEMPLATES - #define JUCE_SUPPORTS_AUv3 1 - #else - #define JUCE_SUPPORTS_AUv3 0 - #endif -#endif - namespace AudioUnitFormatHelpers { #if JUCE_DEBUG @@ -1516,7 +1520,7 @@ private: AutoResizingNSViewComponent wrapper; #if JUCE_SUPPORTS_AUv3 - typedef void (^ViewControllerCallbackBlock)(NSViewController *); + typedef void (^ViewControllerCallbackBlock)(AUViewControllerBase *); ObjCBlock viewControllerCallback; #endif @@ -1617,7 +1621,7 @@ private: } #if JUCE_SUPPORTS_AUv3 - void requestViewControllerCallback (NSViewController* controller) + void requestViewControllerCallback (AUViewControllerBase* controller) { auto nsSize = [controller preferredContentSize]; auto viewSize = CGSizeMake (nsSize.width, nsSize.height); diff --git a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp index d617334574..43ffca2992 100644 --- a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp @@ -22,7 +22,7 @@ ============================================================================== */ -#if JUCE_PLUGINHOST_VST3 +#if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN) } // namespace juce diff --git a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h index f77eb57660..6b1b9810ce 100644 --- a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h +++ b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h @@ -25,7 +25,7 @@ #ifndef JUCE_VST3PLUGINFORMAT_H_INCLUDED #define JUCE_VST3PLUGINFORMAT_H_INCLUDED -#if JUCE_PLUGINHOST_VST3 +#if (JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)) || DOXYGEN /** Implements a plugin format for VST3s. diff --git a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp index fc899123de..e8c53ce510 100644 --- a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp @@ -22,7 +22,7 @@ ============================================================================== */ -#if JUCE_PLUGINHOST_VST +#if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX) //============================================================================== #if JUCE_MAC && JUCE_SUPPORT_CARBON diff --git a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h index 2cd1c99980..dc6ad74975 100644 --- a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h +++ b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h @@ -22,7 +22,7 @@ ============================================================================== */ -#if JUCE_PLUGINHOST_VST || DOXYGEN +#if (JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)) || DOXYGEN //============================================================================== /**