| @@ -137,7 +137,7 @@ endif | |||
| all: $(TARGETS) | |||
| ifneq ($(WIN32),true) | |||
| wine: $(BINDIR)/CarlaVstShell.dll | |||
| wine: $(BINDIR)/CarlaVstShell.dll $(BINDIR)/CarlaVstFXShell.dll | |||
| endif | |||
| # --------------------------------------------------------------------------------------------------------------------- | |||
| @@ -211,6 +211,11 @@ $(BINDIR)/CarlaVstShell.dll: $(OBJDIR)/carla-vst.cpp.shell.o $(OBJDIR)/carla-vst | |||
| -@mkdir -p $(BINDIR) | |||
| @echo "Linking CarlaRackVstShell$(LIB_EXT)" | |||
| @$(WINECC) $^ $(LIBS_START) $(LIBS_wine) $(LIBS_END) $(SHARED) $(WINE_LINK_FLAGS) -o $@ | |||
| $(BINDIR)/CarlaVstFXShell.dll: $(OBJDIR)/carla-vst.cpp.shellfx.o $(OBJDIR)/carla-vst-export.cpp.dll.o carla-vst-export.def | |||
| -@mkdir -p $(BINDIR) | |||
| @echo "Linking CarlaRackVstShell$(LIB_EXT)" | |||
| @$(WINECC) $^ $(LIBS_START) $(LIBS_wine) $(LIBS_END) $(SHARED) $(WINE_LINK_FLAGS) -o $@ | |||
| endif | |||
| $(BINDIR)/CarlaVstShell$(LIB_EXT): $(OBJDIR)/carla-vst.cpp.shell.o $(OBJDIR)/carla-vst-export.cpp.o | |||
| @@ -272,7 +277,12 @@ $(OBJDIR)/carla-vst.cpp.patchbay-syn32.o: carla-vst.cpp | |||
| $(OBJDIR)/carla-vst.cpp.shell.o: carla-vst.cpp | |||
| -@mkdir -p $(OBJDIR) | |||
| @echo "Compiling $< (VstShell)" | |||
| @$(CXX) $< $(BUILD_CXX_FLAGS) -DCARLA_VST_SHELL=1 -c -o $@ | |||
| @$(CXX) $< $(BUILD_CXX_FLAGS) -DCARLA_VST_SHELL=1 -DCARLA_PLUGIN_SYNTH=1 -c -o $@ | |||
| $(OBJDIR)/carla-vst.cpp.shellfx.o: carla-vst.cpp | |||
| -@mkdir -p $(OBJDIR) | |||
| @echo "Compiling $< (VstShell)" | |||
| @$(CXX) $< $(BUILD_CXX_FLAGS) -DCARLA_VST_SHELL=1 -DCARLA_PLUGIN_SYNTH=0 -c -o $@ | |||
| $(OBJDIR)/carla-vst-export.cpp.o: carla-vst-export.cpp | |||
| -@mkdir -p $(OBJDIR) | |||
| @@ -18,14 +18,14 @@ | |||
| #ifdef __WINE__ | |||
| #error This file is not supposed to be built with wine! | |||
| #endif | |||
| #ifndef CARLA_PLUGIN_SYNTH | |||
| #error CARLA_PLUGIN_SYNTH undefined | |||
| #endif | |||
| #ifndef CARLA_VST_SHELL | |||
| #ifndef CARLA_PLUGIN_PATCHBAY | |||
| #error CARLA_PLUGIN_PATCHBAY undefined | |||
| #endif | |||
| #ifndef CARLA_PLUGIN_SYNTH | |||
| #error CARLA_PLUGIN_SYNTH undefined | |||
| #endif | |||
| #if CARLA_PLUGIN_32CH || CARLA_PLUGIN_16CH | |||
| #if ! CARLA_PLUGIN_SYNTH | |||
| #error CARLA_PLUGIN_16/32CH requires CARLA_PLUGIN_SYNTH | |||
| @@ -774,6 +774,11 @@ intptr_t vst_dispatcherCallback(AEffect* effect, int32_t opcode, int32_t index, | |||
| effect->flags &= ~effFlagsIsSynth; | |||
| #endif // CARLA_VST_SHELL | |||
| #if CARLA_PLUGIN_SYNTH | |||
| // override if requested | |||
| effect->flags |= effFlagsIsSynth; | |||
| #endif | |||
| obj->plugin = new NativePlugin(effect, pluginDesc); | |||
| return 1; | |||
| } | |||
| @@ -807,8 +812,12 @@ intptr_t vst_dispatcherCallback(AEffect* effect, int32_t opcode, int32_t index, | |||
| #if CARLA_VST_SHELL | |||
| if (validPlugin) | |||
| { | |||
| #if CARLA_PLUGIN_SYNTH | |||
| return kPlugCategSynth; | |||
| #else | |||
| const NativePluginDescriptor* const desc = pluginPtr->getDescriptor(); | |||
| return desc->category == NATIVE_PLUGIN_CATEGORY_SYNTH ? kPlugCategSynth : kPlugCategEffect; | |||
| #endif | |||
| } | |||
| return kPlugCategShell; | |||
| @@ -1028,9 +1037,9 @@ const AEffect* VSTPluginMainInit(AEffect* const effect) | |||
| effect->flags |= effFlagsProgramChunks; | |||
| #if ! CARLA_VST_SHELL | |||
| effect->flags |= effFlagsHasEditor; | |||
| # if CARLA_PLUGIN_SYNTH | |||
| #endif | |||
| #if CARLA_PLUGIN_SYNTH | |||
| effect->flags |= effFlagsIsSynth; | |||
| # endif | |||
| #endif | |||
| return effect; | |||