@@ -34,6 +34,10 @@ endif | |||
# -------------------------------------------------------------- | |||
ifeq ($(HAVE_OPENGL),true) | |||
BUILD_CXX_FLAGS += -DWANT_OPENGL | |||
endif | |||
ifeq ($(HAVE_AF_DEPS),true) | |||
BUILD_CXX_FLAGS += -DWANT_AUDIOFILE | |||
ifeq ($(HAVE_FFMPEG),true) | |||
@@ -45,10 +49,6 @@ ifeq ($(HAVE_MF_DEPS),true) | |||
BUILD_CXX_FLAGS += -DWANT_MIDIFILE | |||
endif | |||
ifeq ($(HAVE_OPENGL),true) | |||
BUILD_CXX_FLAGS += -DWANT_OPENGL | |||
endif | |||
ifeq ($(HAVE_ZYN_DEPS),true) | |||
BUILD_CXX_FLAGS += -DWANT_ZYNADDSUBFX | |||
ifeq ($(HAVE_ZYN_UI_DEPS),true) | |||
@@ -20,8 +20,8 @@ | |||
#include "CarlaMIDI.h" | |||
#include "RtList.hpp" | |||
#include "RtAudio.h" | |||
#include "RtMidi.h" | |||
#include "rtaudio/RtAudio.h" | |||
#include "rtmidi/RtMidi.h" | |||
#include "juce_audio_basics.h" | |||
@@ -8,29 +8,10 @@ include ../Makefile.mk | |||
# -------------------------------------------------------------- | |||
BUILD_CXX_FLAGS += -DHAVE_GETTIMEOFDAY -D__UNIX_JACK__ | |||
BUILD_CXX_FLAGS += -Irtaudio-4.0.12 -Irtaudio-4.0.12/include -Irtmidi-2.0.1 | |||
BUILD_CXX_FLAGS += $(shell pkg-config --cflags liblo) | |||
ifeq ($(DEBUG),true) | |||
BUILD_CXX_FLAGS += -D__RTAUDIO_DEBUG__ -D__RTMIDI_DEBUG__ | |||
endif | |||
ifeq ($(HAVE_ALSA),true) | |||
BUILD_CXX_FLAGS += $(shell pkg-config --cflags alsa) -D__LINUX_ALSA__ -D__LINUX_ALSASEQ__ | |||
endif | |||
ifeq ($(HAVE_PULSEAUDIO),true) | |||
BUILD_CXX_FLAGS += $(shell pkg-config --cflags libpulse-simple) -D__LINUX_PULSE__ | |||
endif | |||
# ifeq ($(MACOS),true) | |||
# BUILD_CXX_FLAGS += -D__MACOSX_CORE__ | |||
# endif | |||
# ifeq ($(WIN32),true) | |||
# BUILD_CXX_FLAGS += -D__WINDOWS_ASIO__ -D__WINDOWS_DS__ -D__WINDOWS_MM__ | |||
# endif | |||
BUILD_CXX_FLAGS += $(RTAUDIO_FLAGS) | |||
BUILD_CXX_FLAGS += $(RTMIDI_FLAGS) | |||
# -------------------------------------------------------------- | |||
@@ -46,9 +27,9 @@ OBJS = $(OBJSp) \ | |||
CarlaEngineJuce.cpp.o \ | |||
CarlaEngineRtAudio.cpp.o | |||
OBJS += \ | |||
rtaudio-4.0.12/RtAudio.cpp.o \ | |||
rtmidi-2.0.1/RtMidi.cpp.o | |||
HEADERS = \ | |||
../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp \ | |||
CarlaEngineInternal.hpp CarlaEngineOsc.hpp CarlaEngineThread.hpp | |||
TARGET = ../libcarla_engine.a | |||
TARGETp = ../libcarla_engine_plugin.a | |||
@@ -57,25 +38,25 @@ TARGETp = ../libcarla_engine_plugin.a | |||
all: $(TARGET) $(TARGETp) | |||
clean: | |||
rm -f $(OBJS) $(OBJSp) $(TARGET) $(TARGETp) | |||
debug: | |||
$(MAKE) DEBUG=true | |||
# -------------------------------------------------------------- | |||
HEADERS = \ | |||
../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp \ | |||
CarlaEngineInternal.hpp CarlaEngineOsc.hpp CarlaEngineThread.hpp | |||
%.cpp.o: %.cpp $(HEADERS) | |||
$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ | |||
$(TARGET): $(OBJS) | |||
rm -f $@ | |||
$(RM) $@ | |||
$(AR) crs $@ $^ | |||
$(TARGETp): $(OBJSp) | |||
rm -f $@ | |||
$(RM) $@ | |||
$(AR) crs $@ $^ | |||
# -------------------------------------------------------------- | |||
clean: | |||
$(RM) $(OBJS) $(OBJSp) $(TARGET) $(TARGETp) | |||
debug: | |||
$(MAKE) DEBUG=true | |||
# -------------------------------------------------------------- |
@@ -33,23 +33,31 @@ OBJS = \ | |||
FluidSynthPlugin.cpp.o \ | |||
LinuxSamplerPlugin.cpp.o | |||
HEADERS = \ | |||
../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp \ | |||
CarlaPluginInternal.hpp CarlaPluginThread.hpp | |||
TARGET = ../libcarla_plugin.a | |||
# -------------------------------------------------------------- | |||
all: $(TARGET) | |||
clean: | |||
rm -f $(OBJS) $(FILES) $(TARGET) | |||
debug: | |||
$(MAKE) DEBUG=true | |||
# -------------------------------------------------------------- | |||
%.cpp.o: %.cpp ../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp CarlaPluginInternal.hpp CarlaPluginThread.hpp | |||
%.cpp.o: %.cpp $(HEADERS) | |||
$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ | |||
$(TARGET): $(OBJS) | |||
rm -f $@ | |||
$(RM) $@ | |||
$(AR) crs $@ $^ | |||
# -------------------------------------------------------------- | |||
clean: | |||
$(RM) $(OBJS) $(TARGET) | |||
debug: | |||
$(MAKE) DEBUG=true | |||
# -------------------------------------------------------------- |
@@ -13,31 +13,25 @@ BUILD_CXX_FLAGS += $(shell pkg-config --cflags liblo) | |||
# -------------------------------------------------------------- | |||
# Common | |||
LIBS = ../libcarla_engine.a | |||
LIBS += ../libcarla_plugin.a | |||
LINK_FLAGS += $(shell pkg-config --libs liblo) | |||
LINK_FLAGS += -lpthread -ljack | |||
# -------------------------------------------------------------- | |||
# Juce | |||
LINK_FLAGS += $(JACKBRIDGE_LIBS) | |||
LINK_FLAGS += $(JUCE_AUDIO_BASICS_LIBS) | |||
LINK_FLAGS += $(JUCE_CORE_LIBS) | |||
LINK_FLAGS += $(JUCE_DATA_STRUCTURES_LIBS) | |||
LINK_FLAGS += $(JUCE_EVENTS_LIBS) | |||
LINK_FLAGS += $(JUCE_GRAPHICS_LIBS) | |||
LINK_FLAGS += $(JUCE_GUI_BASICS_LIBS) | |||
LINK_FLAGS += $(RTAUDIO_LIBS) | |||
LINK_FLAGS += $(RTMIDI_LIBS) | |||
LINK_FLAGS += $(RTMEMPOOL_LIBS) | |||
# -------------------------------------------------------------- | |||
# Engine | |||
ifeq ($(HAVE_ALSA),true) | |||
LINK_FLAGS += $(shell pkg-config --libs alsa) | |||
ifeq ($(HAVE_OPENGL),true) | |||
LINK_FLAGS += $(DGL_LIBS) | |||
endif | |||
ifeq ($(HAVE_PULSEAUDIO),true) | |||
LINK_FLAGS += $(shell pkg-config --libs libpulse-simple) | |||
ifeq ($(CARLA_PLUGIN_SUPPORT),true) | |||
LINK_FLAGS += $(LILV_LIBS) | |||
endif | |||
# -------------------------------------------------------------- | |||
@@ -75,32 +69,39 @@ LINK_FLAGS += $(shell pkg-config --libs ntk_images ntk) | |||
endif | |||
endif | |||
ifeq ($(HAVE_OPENGL),true) | |||
LINK_FLAGS += $(DGL_LIBS) | |||
endif | |||
# -------------------------------------------------------------- | |||
LIBS = ../libcarla_engine.a | |||
LIBS += ../libcarla_plugin.a | |||
LIBS += ../../modules/carla_native.a | |||
LIBS += ../../modules/jackbridge.a | |||
LIBS += ../../modules/juce_audio_basics.a | |||
LIBS += ../../modules/juce_core.a | |||
LIBS += ../../modules/juce_data_structures.a | |||
LIBS += ../../modules/juce_events.a | |||
LIBS += ../../modules/juce_graphics.a | |||
LIBS += ../../modules/juce_gui_basics.a | |||
LIBS += ../../modules/rtaudio.a | |||
LIBS += ../../modules/rtmidi.a | |||
LIBS += ../../modules/rtmempool.a | |||
ifeq ($(HAVE_OPENGL),true) | |||
LIBS += ../../modules/dgl.a | |||
endif | |||
ifeq ($(CARLA_PLUGIN_SUPPORT),true) | |||
LIBS += ../../modules/lilv.a | |||
endif | |||
ifeq ($(HAVE_OPENGL),true) | |||
LIBS += ../../modules/dgl.a | |||
endif | |||
# -------------------------------------------------------------- | |||
OBJS = \ | |||
CarlaStandalone.cpp.o | |||
HEADERS = \ | |||
../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp ../CarlaHost.hpp ../../modules/CarlaNative.h | |||
ifeq ($(WIN32),true) | |||
TARGET = ../libcarla_standalone2.dll | |||
else | |||
@@ -116,21 +117,21 @@ endif | |||
all: $(TARGET) | |||
clean: | |||
rm -f $(OBJS) $(TARGET) | |||
$(RM) $(OBJS) $(TARGET) | |||
debug: | |||
$(MAKE) DEBUG=true | |||
# -------------------------------------------------------------- | |||
%.cpp.o: %.cpp ../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp ../CarlaHost.hpp | |||
%.cpp.o: %.cpp $(HEADERS) | |||
$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ | |||
../libcarla_standalone2.dll: $(OBJS) $(LIBS) | |||
$(CXX) $^ -shared $(LINK_FLAGS) $(W32_LIBS) -Wl,--output-def,$@.def -o $@ | |||
$(CXX) $^ $(LINK_FLAGS) -shared -Wl,--output-def,$@.def -o $@ | |||
../libcarla_standalone2.dylib: $(OBJS) $(LIBS) | |||
$(CXX) $^ -dynamiclib $(LINK_FLAGS) -framework CoreAudio -framework CoreMIDI -framework CoreFoundation -o $@ | |||
$(CXX) $^ $(LINK_FLAGS) -dynamiclib -o $@ | |||
../libcarla_standalone2.so: $(OBJS) $(LIBS) | |||
$(CXX) $^ $(LINK_FLAGS) -shared -o $@ | |||
@@ -145,3 +146,5 @@ debug: | |||
../../modules/%.a: .FORCE | |||
$(MAKE) -C ../../modules $* | |||
# -------------------------------------------------------------- |