Browse Source

Really fix build, unless compiler crashes..

Signed-off-by: falkTX <falktx@falktx.com>
tags/v2.5.0
falkTX 2 years ago
parent
commit
1ee091f4cc
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
3 changed files with 18 additions and 6 deletions
  1. +8
    -2
      source/backend/plugin/CarlaPluginJuce.cpp
  2. +8
    -2
      source/backend/plugin/CarlaPluginVST2.cpp
  3. +2
    -2
      source/modules/ysfx/Makefile

+ 8
- 2
source/backend/plugin/CarlaPluginJuce.cpp View File

@@ -1652,9 +1652,10 @@ public:
juce::OwnedArray<juce::PluginDescription> pluginDescriptions;
juce::KnownPluginList plist;

#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
{
#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
const ScopedAbortCatcher sac;
#endif

for (int i = 0; i < fFormatManager.getNumFormats(); ++i)
{
@@ -1667,15 +1668,16 @@ public:
plist.scanAndAddFile(fileOrIdentifier, true, pluginDescriptions, *apformat);
} CARLA_SAFE_EXCEPTION_CONTINUE("scanAndAddFile")

#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
if (sac.wasTriggered())
{
carla_stderr("WARNING: Caught exception while scanning file, will not load this plugin");
pluginDescriptions.clearQuick(false);
break;
}
#endif
}
}
#endif

if (pluginDescriptions.size() == 0)
{
@@ -1692,7 +1694,9 @@ public:
juce::String error;

{
#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
const ScopedAbortCatcher sac;
#endif

try {
fInstance = fFormatManager.createPluginInstance(fDesc,
@@ -1701,11 +1705,13 @@ public:
error);
} CARLA_SAFE_EXCEPTION("createPluginInstance")

#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
if (sac.wasTriggered())
{
fInstance = nullptr;
carla_stderr("WARNING: Caught exception while instantiating, will not load this plugin");
}
#endif
}

if (fInstance == nullptr)


+ 8
- 2
source/backend/plugin/CarlaPluginVST2.cpp View File

@@ -2565,10 +2565,11 @@ public:
sCurrentUniqueId = static_cast<intptr_t>(uniqueId);
sLastCarlaPluginVST2 = this;

#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
bool wasTriggered, wasThrown = false;
{
#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
const ScopedAbortCatcher sac;
#endif

try {
fEffect = vstFn(carla_vst_audioMasterCallback);
@@ -2576,19 +2577,24 @@ public:
wasThrown = true;
}

#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
wasTriggered = sac.wasTriggered();
#else
wasTriggered = false;
#endif
}

// try again if plugin blows
if (wasTriggered || wasThrown)
{
#if !(defined(CARLA_OS_WASM) || defined(CARLA_OS_WIN))
const ScopedAbortCatcher sac;
#endif

try {
fEffect = vstFn(carla_vst_audioMasterCallback);
} CARLA_SAFE_EXCEPTION_RETURN("VST init 2nd attempt", false);
}
#endif

sLastCarlaPluginVST2 = nullptr;
sCurrentUniqueId = 0;


+ 2
- 2
source/modules/ysfx/Makefile View File

@@ -53,8 +53,8 @@ ifeq ($(WINDOWS),true)
YSFX_FLAGS += -DNOMINMAX
endif

ifneq ($(WINDOWS)$(CPU_I386),truetrue)
# NOTE: not compatible with MingGW, breaks win32_utf8
ifeq (,$(findstring true,$(WINDOWS)$(CPU_I386)))
# NOTE: not compatible with MingGW or i386 systems
YSFX_FLAGS += -D_FILE_OFFSET_BITS=64
endif



Loading…
Cancel
Save