Browse Source

Linux: Enable ARA compilation

v7.0.9
attila Attila Szarvas 3 years ago
parent
commit
82a31c9ccc
15 changed files with 28 additions and 18 deletions
  1. +3
    -1
      examples/CMakeLists.txt
  2. +1
    -1
      extras/AudioPluginHost/Source/Plugins/ARAPlugin.cpp
  3. +2
    -2
      extras/AudioPluginHost/Source/Plugins/ARAPlugin.h
  4. +2
    -2
      extras/AudioPluginHost/Source/Plugins/PluginGraph.cpp
  5. +1
    -1
      extras/AudioPluginHost/Source/UI/GraphEditorPanel.cpp
  6. +1
    -1
      extras/AudioPluginHost/Source/UI/MainHostWindow.cpp
  7. +1
    -1
      extras/AudioPluginHost/Source/UI/PluginWindow.h
  8. +2
    -1
      extras/Build/CMake/JUCEUtils.cmake
  9. +3
    -0
      extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Make.h
  10. +1
    -1
      modules/juce_audio_processors/format_types/juce_ARACommon.cpp
  11. +4
    -0
      modules/juce_audio_processors/format_types/juce_ARACommon.h
  12. +1
    -1
      modules/juce_audio_processors/format_types/juce_ARAHosting.cpp
  13. +1
    -1
      modules/juce_audio_processors/format_types/juce_ARAHosting.h
  14. +4
    -4
      modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp
  15. +1
    -1
      modules/juce_audio_processors/juce_audio_processors_ara.cpp

+ 3
- 1
examples/CMakeLists.txt View File

@@ -42,7 +42,9 @@ function(_juce_add_pips)
endif()

if(NOT (TARGET juce_ara_sdk
AND (CMAKE_SYSTEM_NAME STREQUAL "Windows" OR CMAKE_SYSTEM_NAME STREQUAL "Darwin")))
AND (CMAKE_SYSTEM_NAME STREQUAL "Windows"
OR CMAKE_SYSTEM_NAME STREQUAL "Darwin"
OR CMAKE_SYSTEM_NAME STREQUAL "Linux")))
list(REMOVE_ITEM headers
"${CMAKE_CURRENT_SOURCE_DIR}/ARAPluginDemo.h")
endif()


+ 1
- 1
extras/AudioPluginHost/Source/Plugins/ARAPlugin.cpp View File

@@ -25,7 +25,7 @@
#include "ARAPlugin.h"
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
const Identifier ARAPluginInstanceWrapper::ARATestHost::Context::xmlRootTag { "ARATestHostContext" };
const Identifier ARAPluginInstanceWrapper::ARATestHost::Context::xmlAudioFileAttrib { "AudioFile" };


+ 2
- 2
extras/AudioPluginHost/Source/Plugins/ARAPlugin.h View File

@@ -27,7 +27,7 @@
#include <juce_core/system/juce_TargetPlatform.h>
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
#include <JuceHeader.h>
@@ -179,7 +179,7 @@ class PlaybackRegion
properties.transformationFlags = ARA::kARAPlaybackTransformationNoChanges;
properties.startInModificationTime = 0.0;
const auto& formatReader = audioSource.getFormatReader();
properties.durationInModificationTime = formatReader.lengthInSamples / formatReader.sampleRate;
properties.durationInModificationTime = (double) formatReader.lengthInSamples / formatReader.sampleRate;
properties.startInPlaybackTime = 0.0;
properties.durationInPlaybackTime = properties.durationInModificationTime;
properties.musicalContextRef = sequence.getMusicalContext().getPluginRef();


+ 2
- 2
extras/AudioPluginHost/Source/Plugins/PluginGraph.cpp View File

@@ -106,7 +106,7 @@ void PluginGraph::addPluginCallback (std::unique_ptr<AudioPluginInstance> instan
}
else
{
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
if (useARA == PluginDescriptionAndPreference::UseARA::yes
&& instance->getPluginDescription().hasARAExtension)
{
@@ -410,7 +410,7 @@ void PluginGraph::createNodeFromXml (const XmlElement& xml)
graph.getBlockSize(),
errorMessage);
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
if (instance
&& description.useARA == PluginDescriptionAndPreference::UseARA::yes
&& description.pluginDescription.hasARAExtension)


+ 1
- 1
extras/AudioPluginHost/Source/UI/GraphEditorPanel.cpp View File

@@ -427,7 +427,7 @@ struct GraphEditorPanel::PluginComponent : public Component,
menu->addItem ("Show all parameters", [this] { showWindow (PluginWindow::Type::generic); });
menu->addItem ("Show debug log", [this] { showWindow (PluginWindow::Type::debug); });
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
if (auto* instance = dynamic_cast<AudioPluginInstance*> (getProcessor()))
if (instance->getPluginDescription().hasARAExtension && isNodeUsingARA())
menu->addItem ("Show ARA host controls", [this] { showWindow (PluginWindow::Type::araHost); });


+ 1
- 1
extras/AudioPluginHost/Source/UI/MainHostWindow.cpp View File

@@ -662,7 +662,7 @@ static void addToMenu (const KnownPluginList::PluginTree& tree,
addPlugin (PluginDescriptionAndPreference { plugin, PluginDescriptionAndPreference::UseARA::no }, name);
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
if (plugin.hasARAExtension)
{
name << " (ARA)";


+ 1
- 1
extras/AudioPluginHost/Source/UI/PluginWindow.h View File

@@ -245,7 +245,7 @@ private:
if (type == PluginWindow::Type::araHost)
{
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
if (auto* araPluginInstanceWrapper = dynamic_cast<ARAPluginInstanceWrapper*> (&processor))
if (auto* ui = araPluginInstanceWrapper->createARAHostEditor())
return ui;


+ 2
- 1
extras/Build/CMake/JUCEUtils.cmake View File

@@ -1910,7 +1910,8 @@ function(juce_add_pip header)

juce_add_plugin(${JUCE_PIP_NAME}
FORMATS AU VST3
IS_ARA_EFFECT TRUE)
IS_ARA_EFFECT TRUE
${extra_target_args})
else()
set(source_main "${JUCE_CMAKE_UTILS_DIR}/PIPAudioProcessor.cpp.in")



+ 3
- 0
extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Make.h View File

@@ -499,6 +499,9 @@ public:
{
vstLegacyPathValueWrapper.init ({ settings, Ids::vstLegacyFolder, nullptr },
getAppSettings().getStoredPath (Ids::vstLegacyPath, TargetOS::linux), TargetOS::linux);
araPathValueWrapper.init ({ settings, Ids::araFolder, nullptr },
getAppSettings().getStoredPath (Ids::araPath, TargetOS::linux), TargetOS::linux);
}
//==============================================================================


+ 1
- 1
modules/juce_audio_processors/format_types/juce_ARACommon.cpp View File

@@ -23,7 +23,7 @@
==============================================================================
*/
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS))
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX))
#include <ARA_Library/Debug/ARADebug.h>


+ 4
- 0
modules/juce_audio_processors/format_types/juce_ARACommon.h View File

@@ -75,6 +75,8 @@ struct ARAFactoryResult
String errorMessage;
};
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wmissing-field-initializers")
template <typename Obj, typename Member, typename... Ts>
constexpr Obj makeARASizedStruct (Member Obj::* member, Ts&&... ts)
{
@@ -82,4 +84,6 @@ constexpr Obj makeARASizedStruct (Member Obj::* member, Ts&&... ts)
std::forward<Ts> (ts)... };
}
JUCE_END_IGNORE_WARNINGS_GCC_LIKE
} // namespace juce

+ 1
- 1
modules/juce_audio_processors/format_types/juce_ARAHosting.cpp View File

@@ -23,7 +23,7 @@
==============================================================================
*/
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS))
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX))
#include "juce_ARAHosting.h"
#include <ARA_Library/Debug/ARADebug.h>


+ 1
- 1
modules/juce_audio_processors/format_types/juce_ARAHosting.h View File

@@ -25,7 +25,7 @@
#pragma once
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS)) || DOXYGEN
#if (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU) && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)) || DOXYGEN
// Include ARA SDK headers
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wgnu-zero-variadic-macro-arguments")


+ 4
- 4
modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp View File

@@ -29,7 +29,7 @@
#include "juce_VST3Common.h"
#include "juce_ARACommon.h"
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
#include <ARA_API/ARAVST3.h>
namespace ARA
@@ -840,7 +840,7 @@ struct DescriptionFactory
// The match is determined by the two classes having the same name.
std::unordered_set<String> araMainFactoryClassNames;
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
for (Steinberg::int32 i = 0; i < numClasses; ++i)
{
PClassInfo info;
@@ -1390,7 +1390,7 @@ static int compareWithString (Type (&charArray)[N], const String& str)
template <typename Callback>
static void forEachARAFactory (IPluginFactory* pluginFactory, Callback&& cb)
{
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
const auto numClasses = pluginFactory->countClasses();
for (Steinberg::int32 i = 0; i < numClasses; ++i)
{
@@ -1413,7 +1413,7 @@ static std::shared_ptr<const ARA::ARAFactory> getARAFactory (Steinberg::IPluginF
{
std::shared_ptr<const ARA::ARAFactory> factory;
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS)
#if JUCE_PLUGINHOST_ARA && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
forEachARAFactory (pluginFactory,
[&pluginFactory, &pluginName, &factory] (const auto& pcClassInfo)
{


+ 1
- 1
modules/juce_audio_processors/juce_audio_processors_ara.cpp View File

@@ -31,7 +31,7 @@
To prevent such problems it's easiest to have it in its own translation unit.
*/
#if (JucePlugin_Enable_ARA || (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU))) && (JUCE_MAC || JUCE_WINDOWS)
#if (JucePlugin_Enable_ARA || (JUCE_PLUGINHOST_ARA && (JUCE_PLUGINHOST_VST3 || JUCE_PLUGINHOST_AU))) && (JUCE_MAC || JUCE_WINDOWS || JUCE_LINUX)
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wgnu-zero-variadic-macro-arguments", "-Wmissing-prototypes")
#include <ARA_Library/Debug/ARADebug.c>


Loading…
Cancel
Save