@@ -471,9 +471,10 @@ doxygen: carla_bridge.doxygen | |||||
clean: | clean: | ||||
rm -f *.o *.dll *.so *.exe | rm -f *.o *.dll *.so *.exe | ||||
rm -f $(OBJS_NATIVE) | |||||
rm -f $(OBJS_POSIX32) | rm -f $(OBJS_POSIX32) | ||||
rm -f $(OBJS_POSIX64) | rm -f $(OBJS_POSIX64) | ||||
rm -f $(OBJS_WIN32) | rm -f $(OBJS_WIN32) | ||||
rm -f $(OBJS_WIN64) | rm -f $(OBJS_WIN64) | ||||
rm -f carla-bridge-lv2-gtk2 carla-bridge-lv2-gtk3 carla-bridge-lv2-qt4 carla-bridge-lv2-qt5 carla-bridge-lv2-x11 carla-bridge-vst-x11 | rm -f carla-bridge-lv2-gtk2 carla-bridge-lv2-gtk3 carla-bridge-lv2-qt4 carla-bridge-lv2-qt5 carla-bridge-lv2-x11 carla-bridge-vst-x11 | ||||
rm -f carla-bridge-posix32 carla-bridge-posix64 | |||||
rm -f carla-bridge-native carla-bridge-posix32 carla-bridge-posix64 |
@@ -1098,10 +1098,8 @@ int main(int argc, char* argv[]) | |||||
void* extraStuff = nullptr; | void* extraStuff = nullptr; | ||||
#if 1 // TESTING | |||||
static const char* const dssiGUI = "/usr/lib/dssi/calf/calf_gtk"; | |||||
extraStuff = (void*)dssiGUI; | |||||
#endif | |||||
if (itype == CarlaBackend::PLUGIN_DSSI) | |||||
extraStuff = findDSSIGUI(filename, name, label); | |||||
// Init plugin | // Init plugin | ||||
short id = engine->addPlugin(itype, filename, name, label, extraStuff); | short id = engine->addPlugin(itype, filename, name, label, extraStuff); | ||||
@@ -1132,6 +1130,9 @@ int main(int argc, char* argv[]) | |||||
ret = 1; | ret = 1; | ||||
} | } | ||||
if (extraStuff && itype == CarlaBackend::PLUGIN_DSSI) | |||||
free((char*)extraStuff); | |||||
engine->aboutToClose(); | engine->aboutToClose(); | ||||
engine->removeAllPlugins(); | engine->removeAllPlugins(); | ||||
engine->close(); | engine->close(); | ||||
@@ -17,6 +17,9 @@ | |||||
#include "Shared.hpp" | #include "Shared.hpp" | ||||
#include <QtCore/QDir> | |||||
#include <QtCore/QFileInfo> | |||||
//#define __STDC_LIMIT_MACROS | //#define __STDC_LIMIT_MACROS | ||||
//#include <cstdint> | //#include <cstdint> | ||||
@@ -255,3 +258,42 @@ QString xmlSafeString(QString string, const bool toXml) | |||||
else | else | ||||
return string.replace("&", "&").replace("<","<").replace(">",">").replace("'","'").replace(""","\""); | return string.replace("&", "&").replace("<","<").replace(">",">").replace("'","'").replace(""","\""); | ||||
} | } | ||||
// ------------------------------------------------------------------------------------------------------------ | |||||
// Plugin Query (helper functions) | |||||
char* findDSSIGUI(const char* const filename, const char* const name, const char* const label) | |||||
{ | |||||
static QString guiFilename; | |||||
guiFilename.clear(); | |||||
QString pluginDir(filename); | |||||
pluginDir.resize(pluginDir.lastIndexOf(".")); | |||||
QString shortName = QFileInfo(pluginDir).baseName(); | |||||
QString checkName = QString(name).replace(" ", "_"); | |||||
QString checkLabel = QString(label); | |||||
QString checkSName = shortName; | |||||
if (! checkName.endsWith("_")) checkName += "_"; | |||||
if (! checkLabel.endsWith("_")) checkLabel += "_"; | |||||
if (! checkSName.endsWith("_")) checkSName += "_"; | |||||
QStringList guiFiles = QDir(pluginDir).entryList(); | |||||
foreach (const QString& gui, guiFiles) | |||||
{ | |||||
if (gui.startsWith(checkName) || gui.startsWith(checkLabel) || gui.startsWith(checkSName)) | |||||
{ | |||||
QFileInfo finalname(pluginDir + QDir::separator() + gui); | |||||
guiFilename = finalname.absoluteFilePath(); | |||||
break; | |||||
} | |||||
} | |||||
if (guiFilename.isEmpty()) | |||||
return nullptr; | |||||
return strdup(guiFilename.toUtf8().constData()); | |||||
} |
@@ -148,4 +148,12 @@ const CarlaSaveState* getSaveStateDictFromXML(const QDomNode& xmlNode); | |||||
QString xmlSafeString(QString string, const bool toXml); | QString xmlSafeString(QString string, const bool toXml); | ||||
// ------------------------------------------------------------------------------------------------------------ | |||||
// Plugin Query (helper functions) | |||||
// needs free() afterwars if valid | |||||
char* findDSSIGUI(const char* const filename, const char* const name, const char* const label); | |||||
// ------------------------------------------------------------------------------------------------------------ | |||||
#endif // SHARED_HPP | #endif // SHARED_HPP |
@@ -213,6 +213,9 @@ class ClaudiaLauncher(QWidget, ui_claudia_launcher.Ui_ClaudiaLauncherW): | |||||
if binary.startswith("startBristol"): | if binary.startswith("startBristol"): | ||||
self.createAppTemplate("bristol", app, binary) | self.createAppTemplate("bristol", app, binary) | ||||
elif binary.startswith("carla-standalone"): | |||||
self.createAppTemplate("carla-standalone", app, binary) | |||||
elif app == "Ardour 2.8": | elif app == "Ardour 2.8": | ||||
self.createAppTemplate("ardour2", app, binary) | self.createAppTemplate("ardour2", app, binary) | ||||
@@ -737,7 +740,7 @@ class ClaudiaLauncher(QWidget, ui_claudia_launcher.Ui_ClaudiaLauncherW): | |||||
if not "bristol" in pkglist: | if not "bristol" in pkglist: | ||||
self.tabWidget.setTabEnabled(iTabBristol, False) | self.tabWidget.setTabEnabled(iTabBristol, False) | ||||
if not ("carla-bridge-linux32" in pkglist or "carla-bridge-linux64" in pkglist): | |||||
if not ("carla" in pkglist or "cadence-git" in pkglist): | |||||
self.tabWidget.setTabEnabled(iTabPlugin, False) | self.tabWidget.setTabEnabled(iTabPlugin, False) | ||||
last_pos = 0 | last_pos = 0 | ||||