From cac8548a582bb62a19d40fc1de9604cd2a8bb162 Mon Sep 17 00:00:00 2001 From: asb2m10 Date: Thu, 27 Mar 2014 23:26:36 -0400 Subject: [PATCH] Initial Linux support --- Builds/Linux/Makefile | 276 ++++++++++++++++++++++++++++++++++++++ Dexed.jucer | 22 +++ README.md | 4 + Source/DXComponents.cpp | 1 + Source/OperatorEditor.cpp | 2 +- Source/PluginEditor.cpp | 12 +- Source/PluginParam.cpp | 10 +- Source/msfa/aligned_buf.h | 2 + 8 files changed, 317 insertions(+), 12 deletions(-) create mode 100644 Builds/Linux/Makefile diff --git a/Builds/Linux/Makefile b/Builds/Linux/Makefile new file mode 100644 index 0000000..3c6fd5b --- /dev/null +++ b/Builds/Linux/Makefile @@ -0,0 +1,276 @@ +# Automatically generated makefile, created by the Introjucer +# Don't edit this file! Your changes will be overwritten when you re-save the Introjucer project! + +# (this disables dependency generation if multiple architectures are set) +DEPFLAGS := $(if $(word 2, $(TARGET_ARCH)), , -MMD) + +ifndef CONFIG + CONFIG=Debug +endif + +ifeq ($(CONFIG),Debug) + BINDIR := build + LIBDIR := build + OBJDIR := build/intermediate/Debug + OUTDIR := build + + ifeq ($(TARGET_ARCH),) + TARGET_ARCH := -march=native + endif + + CPPFLAGS := $(DEPFLAGS) -D "LINUX=1" -D "DEBUG=1" -D "_DEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=1.0.0" -D "JUCE_APP_VERSION_HEX=0x10000" -I /usr/include -I /usr/include/freetype2 -I ~/src/vstsdk2.4 -I ../../JuceLibraryCode -I ../../JuceLibraryCode/modules + CFLAGS += $(CPPFLAGS) $(TARGET_ARCH) -g -ggdb -fPIC -O0 + CXXFLAGS += $(CFLAGS) + LDFLAGS += $(TARGET_ARCH) -L$(BINDIR) -L$(LIBDIR) -shared -L/usr/X11R6/lib/ -lX11 -lXext -lXinerama -lasound -ldl -lfreetype -lpthread -lrt + LDDEPS := + RESFLAGS := -D "LINUX=1" -D "DEBUG=1" -D "_DEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=1.0.0" -D "JUCE_APP_VERSION_HEX=0x10000" -I /usr/include -I /usr/include/freetype2 -I ~/src/vstsdk2.4 -I ../../JuceLibraryCode -I ../../JuceLibraryCode/modules + TARGET := Dexed.so + BLDCMD = $(CXX) -o $(OUTDIR)/$(TARGET) $(OBJECTS) $(LDFLAGS) $(RESOURCES) $(TARGET_ARCH) + CLEANCMD = rm -rf $(OUTDIR)/$(TARGET) $(OBJDIR) +endif + +ifeq ($(CONFIG),Release) + BINDIR := build + LIBDIR := build + OBJDIR := build/intermediate/Release + OUTDIR := build + + ifeq ($(TARGET_ARCH),) + TARGET_ARCH := -march=native + endif + + CPPFLAGS := $(DEPFLAGS) -D "LINUX=1" -D "NDEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=1.0.0" -D "JUCE_APP_VERSION_HEX=0x10000" -I /usr/include -I /usr/include/freetype2 -I ~/src/vstsdk2.4 -I ../../JuceLibraryCode -I ../../JuceLibraryCode/modules + CFLAGS += $(CPPFLAGS) $(TARGET_ARCH) -fPIC -Os + CXXFLAGS += $(CFLAGS) + LDFLAGS += $(TARGET_ARCH) -L$(BINDIR) -L$(LIBDIR) -shared -fvisibility=hidden -L/usr/X11R6/lib/ -lX11 -lXext -lXinerama -lasound -ldl -lfreetype -lpthread -lrt + LDDEPS := + RESFLAGS := -D "LINUX=1" -D "NDEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=1.0.0" -D "JUCE_APP_VERSION_HEX=0x10000" -I /usr/include -I /usr/include/freetype2 -I ~/src/vstsdk2.4 -I ../../JuceLibraryCode -I ../../JuceLibraryCode/modules + TARGET := Dexed.so + BLDCMD = $(CXX) -o $(OUTDIR)/$(TARGET) $(OBJECTS) $(LDFLAGS) $(RESOURCES) $(TARGET_ARCH) + CLEANCMD = rm -rf $(OUTDIR)/$(TARGET) $(OBJDIR) +endif + +OBJECTS := \ + $(OBJDIR)/PluginProcessor_a059e380.o \ + $(OBJDIR)/PluginParam_c683be7b.o \ + $(OBJDIR)/PluginData_e9169086.o \ + $(OBJDIR)/freqlut_ca864b55.o \ + $(OBJDIR)/lfo_a7533573.o \ + $(OBJDIR)/dx7note_176ee213.o \ + $(OBJDIR)/env_9bd533bb.o \ + $(OBJDIR)/exp2_ef8e37bf.o \ + $(OBJDIR)/fm_core_963f4751.o \ + $(OBJDIR)/fm_op_kernel_f831cdd1.o \ + $(OBJDIR)/pitchenv_d3341dc7.o \ + $(OBJDIR)/sin_b36ef3f0.o \ + $(OBJDIR)/PluginEditor_94d4fb09.o \ + $(OBJDIR)/GlobalEditor_4b9bc379.o \ + $(OBJDIR)/ParamDialog_aca81c16.o \ + $(OBJDIR)/OperatorEditor_b03d363a.o \ + $(OBJDIR)/DXLookNFeel_cfc3afa2.o \ + $(OBJDIR)/DXComponents_a6963633.o \ + $(OBJDIR)/PluginFx_d84f776e.o \ + $(OBJDIR)/BinaryData_ce4232d4.o \ + $(OBJDIR)/juce_audio_basics_2442e4ea.o \ + $(OBJDIR)/juce_audio_devices_a4c8a728.o \ + $(OBJDIR)/juce_audio_formats_d349f0c8.o \ + $(OBJDIR)/juce_audio_processors_44a134a2.o \ + $(OBJDIR)/juce_audio_utils_f63b12e8.o \ + $(OBJDIR)/juce_core_aff681cc.o \ + $(OBJDIR)/juce_data_structures_bdd6d488.o \ + $(OBJDIR)/juce_events_79b2840.o \ + $(OBJDIR)/juce_graphics_c8f1e7a4.o \ + $(OBJDIR)/juce_gui_basics_a630dd20.o \ + $(OBJDIR)/juce_gui_extra_7767d6a8.o \ + $(OBJDIR)/juce_PluginUtilities_e2e19a34.o \ + $(OBJDIR)/juce_VST3_Wrapper_77e7c73b.o \ + $(OBJDIR)/juce_VST_Wrapper_bb62e93d.o \ + +.PHONY: clean + +$(OUTDIR)/$(TARGET): $(OBJECTS) $(LDDEPS) $(RESOURCES) + @echo Linking Dexed + -@mkdir -p $(BINDIR) + -@mkdir -p $(LIBDIR) + -@mkdir -p $(OUTDIR) + @$(BLDCMD) + +clean: + @echo Cleaning Dexed + @$(CLEANCMD) + +strip: + @echo Stripping Dexed + -@strip --strip-unneeded $(OUTDIR)/$(TARGET) + +$(OBJDIR)/PluginProcessor_a059e380.o: ../../Source/PluginProcessor.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling PluginProcessor.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/PluginParam_c683be7b.o: ../../Source/PluginParam.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling PluginParam.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/PluginData_e9169086.o: ../../Source/PluginData.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling PluginData.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/freqlut_ca864b55.o: ../../Source/msfa/freqlut.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling freqlut.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/lfo_a7533573.o: ../../Source/msfa/lfo.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling lfo.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/dx7note_176ee213.o: ../../Source/msfa/dx7note.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling dx7note.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/env_9bd533bb.o: ../../Source/msfa/env.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling env.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/exp2_ef8e37bf.o: ../../Source/msfa/exp2.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling exp2.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/fm_core_963f4751.o: ../../Source/msfa/fm_core.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling fm_core.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/fm_op_kernel_f831cdd1.o: ../../Source/msfa/fm_op_kernel.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling fm_op_kernel.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/pitchenv_d3341dc7.o: ../../Source/msfa/pitchenv.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling pitchenv.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/sin_b36ef3f0.o: ../../Source/msfa/sin.cc + -@mkdir -p $(OBJDIR) + @echo "Compiling sin.cc" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/PluginEditor_94d4fb09.o: ../../Source/PluginEditor.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling PluginEditor.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/GlobalEditor_4b9bc379.o: ../../Source/GlobalEditor.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling GlobalEditor.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/ParamDialog_aca81c16.o: ../../Source/ParamDialog.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling ParamDialog.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/OperatorEditor_b03d363a.o: ../../Source/OperatorEditor.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling OperatorEditor.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/DXLookNFeel_cfc3afa2.o: ../../Source/DXLookNFeel.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling DXLookNFeel.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/DXComponents_a6963633.o: ../../Source/DXComponents.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling DXComponents.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/PluginFx_d84f776e.o: ../../Source/PluginFx.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling PluginFx.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/BinaryData_ce4232d4.o: ../../JuceLibraryCode/BinaryData.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling BinaryData.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_audio_basics_2442e4ea.o: ../../JuceLibraryCode/modules/juce_audio_basics/juce_audio_basics.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_audio_basics.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_audio_devices_a4c8a728.o: ../../JuceLibraryCode/modules/juce_audio_devices/juce_audio_devices.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_audio_devices.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_audio_formats_d349f0c8.o: ../../JuceLibraryCode/modules/juce_audio_formats/juce_audio_formats.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_audio_formats.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_audio_processors_44a134a2.o: ../../JuceLibraryCode/modules/juce_audio_processors/juce_audio_processors.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_audio_processors.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_audio_utils_f63b12e8.o: ../../JuceLibraryCode/modules/juce_audio_utils/juce_audio_utils.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_audio_utils.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_core_aff681cc.o: ../../JuceLibraryCode/modules/juce_core/juce_core.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_core.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_data_structures_bdd6d488.o: ../../JuceLibraryCode/modules/juce_data_structures/juce_data_structures.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_data_structures.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_events_79b2840.o: ../../JuceLibraryCode/modules/juce_events/juce_events.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_events.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_graphics_c8f1e7a4.o: ../../JuceLibraryCode/modules/juce_graphics/juce_graphics.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_graphics.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_gui_basics_a630dd20.o: ../../JuceLibraryCode/modules/juce_gui_basics/juce_gui_basics.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_gui_basics.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_gui_extra_7767d6a8.o: ../../JuceLibraryCode/modules/juce_gui_extra/juce_gui_extra.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_gui_extra.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_PluginUtilities_e2e19a34.o: ../../JuceLibraryCode/modules/juce_audio_plugin_client/utility/juce_PluginUtilities.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_PluginUtilities.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_VST3_Wrapper_77e7c73b.o: ../../JuceLibraryCode/modules/juce_audio_plugin_client/VST3/juce_VST3_Wrapper.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_VST3_Wrapper.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +$(OBJDIR)/juce_VST_Wrapper_bb62e93d.o: ../../JuceLibraryCode/modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp + -@mkdir -p $(OBJDIR) + @echo "Compiling juce_VST_Wrapper.cpp" + @$(CXX) $(CXXFLAGS) -o "$@" -c "$<" + +-include $(OBJECTS:%.o=%.d) diff --git a/Dexed.jucer b/Dexed.jucer index ac1768d..3c29a21 100644 --- a/Dexed.jucer +++ b/Dexed.jucer @@ -137,6 +137,28 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/README.md b/README.md index ebe6d29..32f58ed 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,10 @@ Features Changelog --------- + +#### Version 0.5.0 (current sprint) +* Offical Linux support + #### Version 0.4.0 * Modulation wheel support * Now using the [Obxd](https://obxd.wordpress.com) 4-pole lowpass filter implementation diff --git a/Source/DXComponents.cpp b/Source/DXComponents.cpp index 9dcc162..e1b522b 100644 --- a/Source/DXComponents.cpp +++ b/Source/DXComponents.cpp @@ -444,6 +444,7 @@ LcdDisplay::LcdDisplay() { void LcdDisplay::timerCallback() { systemMsg = "*** DEXED FM synthesizer ***"; repaint(); + stopTimer(); } void LcdDisplay::setSystemMsg(String msg) { diff --git a/Source/OperatorEditor.cpp b/Source/OperatorEditor.cpp index 733eaaa..cfbf46b 100644 --- a/Source/OperatorEditor.cpp +++ b/Source/OperatorEditor.cpp @@ -472,7 +472,7 @@ void OperatorEditor::updateDisplay() { else txtFreq << " " << det; } - khzDisplay->setText(txtFreq, NotificationType::dontSendNotification); + khzDisplay->setText(txtFreq, dontSendNotification); envDisplay->repaint(); } diff --git a/Source/PluginEditor.cpp b/Source/PluginEditor.cpp index 380e336..d841287 100644 --- a/Source/PluginEditor.cpp +++ b/Source/PluginEditor.cpp @@ -47,7 +47,7 @@ public: g.drawImage (about_png, 0, 0, about_png.getWidth(), about_png.getHeight(), 0, 0, about_png.getWidth(), about_png.getHeight()); g.setColour(Colour(0xFF000000)); - String ver("Version 0.4 ; built date " __DATE__ ); + String ver("Version 0.5 ; built date " __DATE__ ); g.drawSingleLineText(ver, 9, 118); } }; @@ -170,7 +170,7 @@ void DexedAudioProcessorEditor::buttonClicked(Button *buttonThatWasClicked) { processor->loadBuiltin(result-1); processor->setCurrentProgram(0); rebuildProgramCombobox(); - programs.setSelectedId(processor->getCurrentProgram()+1, NotificationType::dontSendNotification); + programs.setSelectedId(processor->getCurrentProgram()+1, dontSendNotification); processor->updateHostDisplay(); return; } @@ -195,7 +195,7 @@ void DexedAudioProcessorEditor::buttonClicked(Button *buttonThatWasClicked) { } processor->setCurrentProgram(0); rebuildProgramCombobox(); - programs.setSelectedId(processor->getCurrentProgram()+1, NotificationType::dontSendNotification); + programs.setSelectedId(processor->getCurrentProgram()+1, dontSendNotification); processor->updateHostDisplay(); } @@ -288,19 +288,19 @@ void DexedAudioProcessorEditor::updateUI() { } int id = processor->getCurrentProgram() + 1; - programs.setSelectedId(id, NotificationType::dontSendNotification); + programs.setSelectedId(id, dontSendNotification); global.updateDisplay(); } void DexedAudioProcessorEditor::rebuildProgramCombobox() { - programs.clear(NotificationType::dontSendNotification); + programs.clear(dontSendNotification); for(int i=0;igetNumPrograms();i++) { String id; id << (i+1) << ". " << processor->getProgramName(i); programs.addItem(id, i+1); } - programs.setSelectedId(processor->getCurrentProgram()+1, NotificationType::dontSendNotification); + programs.setSelectedId(processor->getCurrentProgram()+1, dontSendNotification); } void DexedAudioProcessorEditor::storeProgram() { diff --git a/Source/PluginParam.cpp b/Source/PluginParam.cpp index b777afa..8c1d411 100644 --- a/Source/PluginParam.cpp +++ b/Source/PluginParam.cpp @@ -108,7 +108,7 @@ String CtrlFloat::getValueDisplay() { void CtrlFloat::updateComponent() { if (slider != NULL) { - slider->setValue(*vPointer, NotificationType::dontSendNotification); + slider->setValue(*vPointer, dontSendNotification); } } @@ -180,16 +180,16 @@ void CtrlDX::comboBoxChanged(ComboBox* combo) { void CtrlDX::updateComponent() { if (slider != NULL) { slider->setValue(getValue() + displayValue, - NotificationType::dontSendNotification); + dontSendNotification); } if (button != NULL) { if (getValue() == 0) { button->setToggleState(false, - NotificationType::dontSendNotification); + dontSendNotification); } else { button->setToggleState(true, - NotificationType::dontSendNotification); + dontSendNotification); } } @@ -198,7 +198,7 @@ void CtrlDX::updateComponent() { if (comboBox->getNumItems() <= cvalue) { cvalue = comboBox->getNumItems(); } - comboBox->setSelectedId(cvalue, NotificationType::dontSendNotification); + comboBox->setSelectedId(cvalue, dontSendNotification); } } diff --git a/Source/msfa/aligned_buf.h b/Source/msfa/aligned_buf.h index 70aef2a..5cd1544 100755 --- a/Source/msfa/aligned_buf.h +++ b/Source/msfa/aligned_buf.h @@ -21,6 +21,8 @@ #ifndef __ALIGNED_BUF_H #define __ALIGNED_BUF_H +#include + template class AlignedBuf { public: