diff options
author | yuri <yuri@FreeBSD.org> | 2018-11-18 17:35:41 +0800 |
---|---|---|
committer | yuri <yuri@FreeBSD.org> | 2018-11-18 17:35:41 +0800 |
commit | 9f43166de5af8ddec24f8333d7ce7dda1de779f5 (patch) | |
tree | 6492d9f363f18f562799d4a75b4be06d981596bc /audio | |
parent | 27c4bb5886ddadfaabb8fe98222ac9ae80fb530f (diff) | |
download | freebsd-ports-gnome-9f43166de5af8ddec24f8333d7ce7dda1de779f5.tar.gz freebsd-ports-gnome-9f43166de5af8ddec24f8333d7ce7dda1de779f5.tar.zst freebsd-ports-gnome-9f43166de5af8ddec24f8333d7ce7dda1de779f5.zip |
New port: audio/csoundqt: Csound frontend with editor, integrated help, widgets, other features
Diffstat (limited to 'audio')
-rw-r--r-- | audio/Makefile | 1 | ||||
-rw-r--r-- | audio/csoundqt/Makefile | 45 | ||||
-rw-r--r-- | audio/csoundqt/distinfo | 3 | ||||
-rw-r--r-- | audio/csoundqt/files/patch-qcs.pro | 18 | ||||
-rw-r--r-- | audio/csoundqt/files/patch-src_qutecsound.cpp | 96 | ||||
-rw-r--r-- | audio/csoundqt/pkg-descr | 13 |
6 files changed, 176 insertions, 0 deletions
diff --git a/audio/Makefile b/audio/Makefile index 5728d6adebb4..c73b92f99d49 100644 --- a/audio/Makefile +++ b/audio/Makefile @@ -94,6 +94,7 @@ SUBDIR += creox SUBDIR += crip SUBDIR += csound + SUBDIR += csoundqt SUBDIR += ctronome SUBDIR += cue2toc SUBDIR += cueplayer diff --git a/audio/csoundqt/Makefile b/audio/csoundqt/Makefile new file mode 100644 index 000000000000..f0d1ffdc0fbe --- /dev/null +++ b/audio/csoundqt/Makefile @@ -0,0 +1,45 @@ +# $FreeBSD$ + +PORTNAME= CsoundQt +DISTVERSION= 0.9.5 +CATEGORIES= audio + +MAINTAINER= yuri@FreeBSD.org +COMMENT= Csound frontend with editor, integrated help, widgets, other features + +LICENSE= LGPL21 +LICENSE_FILE= ${WRKSRC}/lgpl-2.1.txt + +LIB_DEPENDS= libcsound64.so:audio/csound + +USES= compiler:c++11-lib desktop-file-utils gl gmake qmake qt:5 shared-mime-info +USE_GITHUB= yes +USE_QT= concurrent core declarative gui network printsupport widgets xml buildtools_build +USE_GL= gl + +QMAKE_ARGS= CONFIG+="CSOUND_API_INCLUDE_DIR=${LOCALBASE}/include/csound CSOUND_LIBRARY_DIR=${LOCALBASE}/lib build64" \ + INSTALL_DIR=${PREFIX} SHARE_DIR=${PREFIX}/share \ + qcs.pro + +PLIST_FILES= bin/${PORTNAME}-d-cs6 \ + bin/csoundqt \ + share/applications/${PORTNAME}.desktop \ + share/icons/hicolor/128x128/mimetypes/csound.png \ + share/icons/hicolor/scalable/apps/qtcs.svg \ + share/mime/packages/x-csound-csd.xml \ + share/mime/packages/x-csound-orc.xml \ + share/mime/packages/x-csound-sco.xml + +OPTIONS_DEFINE= EXAMPLES + +PORTEXAMPLES= * + +post-patch: + @${REINPLACE_CMD} 's|Q_OS_LINUX|Q_OS_FREEBSD| ; s|/usr/|${LOCALBASE}/|' ${WRKSRC}/src/types.h + +post-install: + @${MV} ${STAGEDIR}${DATADIR}/Examples ${STAGEDIR}${EXAMPLESDIR} + @${RMDIR} ${STAGEDIR}${DATADIR} + @${STRIP_CMD} ${STAGEDIR}${LOCALBASE}/bin/${PORTNAME}-d-cs6 + +.include <bsd.port.mk> diff --git a/audio/csoundqt/distinfo b/audio/csoundqt/distinfo new file mode 100644 index 000000000000..6ec6e7079f6d --- /dev/null +++ b/audio/csoundqt/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1542489209 +SHA256 (CsoundQt-CsoundQt-0.9.5_GH0.tar.gz) = adf9c48be719226ec553cc67019b191d1730f6643ee41ce2996cd3a88dd12eab +SIZE (CsoundQt-CsoundQt-0.9.5_GH0.tar.gz) = 64382619 diff --git a/audio/csoundqt/files/patch-qcs.pro b/audio/csoundqt/files/patch-qcs.pro new file mode 100644 index 000000000000..956b9998fc3b --- /dev/null +++ b/audio/csoundqt/files/patch-qcs.pro @@ -0,0 +1,18 @@ +--- qcs.pro.orig 2018-11-18 08:13:18 UTC ++++ qcs.pro +@@ -187,13 +187,13 @@ unix:!macx { + desktop.path=$$SHARE_DIR/applications + desktop.files=CsoundQt.desktop + +- icon.path=$$SHARE_DIR/icons # not sure in fact, if /usr/share/icons is enough or better to put into hicolor... ++ icon.path=$$SHARE_DIR/icons/hicolor/scalable/apps/ # not sure in fact, if /usr/share/icons is enough or better to put into hicolor... + icon.files=images/qtcs.svg + + mimetypes.path=$$INSTALL_DIR # in some reason path must be set to create install target in Makefile + mimetypes.commands = cd $$PWD/mime-types/; ./add_csound_mimetypes.sh $(INSTALL_ROOT)/$$INSTALL_DIR + +- examples.path = $$SHARE_DIR/qutecsound/ ++ examples.path = $$SHARE_DIR/CsoundQt/ + examples.files = src/Examples + + INSTALLS += target desktop icon mimetypes examples diff --git a/audio/csoundqt/files/patch-src_qutecsound.cpp b/audio/csoundqt/files/patch-src_qutecsound.cpp new file mode 100644 index 000000000000..fe1194e4fa9e --- /dev/null +++ b/audio/csoundqt/files/patch-src_qutecsound.cpp @@ -0,0 +1,96 @@ +--- src/qutecsound.cpp.orig 2017-11-19 10:59:36 UTC ++++ src/qutecsound.cpp +@@ -267,6 +267,9 @@ CsoundQt::CsoundQt(QStringList fileNames + #ifdef Q_OS_LINUX + possibleDirectories << "/usr/share/doc/csound-manual/html/" << "/usr/share/doc/csound-doc/html/"; + #endif ++#ifdef Q_OS_FREEBSD ++ possibleDirectories << initialDir+"/../share/doc/csound-manual/html/" << initialDir+"/../share/doc/csound-doc/html/"; ++#endif + #ifdef Q_OS_WIN + QString programFilesPath = QDir::fromNativeSeparators(getenv("PROGRAMFILES")); + QString programFilesPathx86 = QDir::fromNativeSeparators(getenv("PROGRAMFILES(X86)")); +@@ -1255,6 +1258,8 @@ void CsoundQt::createApp() + #ifdef USE_DOUBLE + #ifdef Q_OS_LINUX + #endif ++#ifdef Q_OS_FREEBSD ++#endif + #ifdef Q_OS_SOLARIS + #endif + #ifdef Q_OS_WIN32 +@@ -1267,6 +1272,8 @@ void CsoundQt::createApp() + + #ifdef Q_OS_LINUX + #endif ++#ifdef Q_OS_FREEBSD ++#endif + #ifdef Q_OS_SOLARS + #endif + #ifdef Q_OS_WIN32 +@@ -1314,10 +1321,10 @@ void CsoundQt::createApp() + wizard.setField("targetDir", appDir); + if (m_options->sdkDir.isEmpty()) { // No sdk, + wizard.setField("customPaths", true); +-#if defined(Q_OS_LINUX) || defined(Q_OS_SOLARIS) +- wizard.setField("libDir", "/usr/lib"); ++#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) || defined(Q_OS_SOLARIS) ++ wizard.setField("libDir", QCoreApplication::applicationDirPath()+"/../lib"); + if (opcodeDir.isEmpty()) { +- wizard.setField("opcodeDir", "/usr/lib/csound/plugins"); ++ wizard.setField("opcodeDir", QCoreApplication::applicationDirPath()+"/../lib/csound/plugins64-6.0"); + } + #endif + #ifdef Q_OS_WIN32 +@@ -1810,6 +1817,9 @@ void CsoundQt::runInTerm(bool realtime) + #ifdef Q_OS_LINUX + options = "-e " + scriptFileName; + #endif ++#ifdef Q_OS_FREEBSD ++ options = "-e " + scriptFileName; ++#endif + #ifdef Q_OS_SOLARIS + options = "-e " + scriptFileName; + #endif +@@ -2797,6 +2807,9 @@ void CsoundQt::runUtility(QString flags) + #ifdef Q_OS_LINUX + options = "-e " + SCRIPT_NAME; + #endif ++#ifdef Q_OS_FREEBSD ++ options = "-e " + SCRIPT_NAME; ++#endif + #ifdef Q_OS_SOLARIS + options = "-e " + SCRIPT_NAME; + #endif +@@ -3911,10 +3924,10 @@ QString CsoundQt::getExamplePath(QString + examplePath = qApp->applicationDirPath() + "/../Resources/" + dir; + qDebug() << examplePath; + #endif +-#ifdef Q_OS_LINUX ++#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) + examplePath = qApp->applicationDirPath() + "/Examples/" + dir; + if (!QDir(examplePath).exists()) { +- examplePath = qApp->applicationDirPath() + "/../src/Examples/" + dir; ++ examplePath = qApp->applicationDirPath() + "/../share/examples/CsoundQt/" + dir; + } + if (!QDir(examplePath).exists()) { // for out of tree builds + examplePath = qApp->applicationDirPath() + "/../../csoundqt/src/Examples/" + dir; +@@ -4380,7 +4393,7 @@ void CsoundQt::fillFileMenu() + templatePath = qApp->applicationDirPath() + "/../templates/"; + qDebug() << templatePath; + #endif +-#ifdef Q_OS_LINUX ++#if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) + templatePath = qApp->applicationDirPath() + "/templates/"; + if (!QDir(templatePath).exists()) { + templatePath = qApp->applicationDirPath() + "/../templates/"; +@@ -5058,6 +5071,9 @@ int CsoundQt::execute(QString executable + #ifdef Q_OS_LINUX + QString commandLine = "\"" + executable + "\" " + options; + #endif ++#ifdef Q_OS_FREEBSD ++ QString commandLine = "\"" + executable + "\" " + options; ++#endif + #ifdef Q_OS_HAIKU + QString commandLine = "\"" + executable + "\" " + options; + #endif diff --git a/audio/csoundqt/pkg-descr b/audio/csoundqt/pkg-descr new file mode 100644 index 000000000000..88d73ca8fed4 --- /dev/null +++ b/audio/csoundqt/pkg-descr @@ -0,0 +1,13 @@ +CsoundQt is a frontend for Csound featuring a highlighting editor with +autocomplete, interactive widgets and integrated help. It is a cross-platform +and aims to be a simple yet powerful and complete development environment for +Csound. It can open files created by MacCsound. Csound is a musical programming +language with a very long history, with roots in the origins of computer music. +It is still being maintained by an active community and despite its age, is +still one of the most powerful tools for sound processing and synthesis. +CsoundQt hopes to bring the power of Csound to a larger group of people, by +reducing Csound's intial learning curve, and by giving users more immediate +control of their sound. It hopes to be both a simple tool for the beginner, as +well as a powerful tool for experienced users. + +WWW: https://csoundqt.github.io/ |