aboutsummaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authoryuri <yuri@FreeBSD.org>2018-11-18 04:27:32 +0800
committeryuri <yuri@FreeBSD.org>2018-11-18 04:27:32 +0800
commitd3e7f49caa6e2d4582432d786962b2b5cb86354d (patch)
tree9b2ba4c858bc48fa3510b250646e58b8ad5b4845 /audio
parente3a074111a62a01f4e944abaf36788ec1dffa500 (diff)
downloadfreebsd-ports-gnome-d3e7f49caa6e2d4582432d786962b2b5cb86354d.tar.gz
freebsd-ports-gnome-d3e7f49caa6e2d4582432d786962b2b5cb86354d.tar.zst
freebsd-ports-gnome-d3e7f49caa6e2d4582432d786962b2b5cb86354d.zip
audio/csound6: Fix build; Update 6.06.0 -> 6.12.2
Massive changes: * Add all plugins as individual options * Add many missing dependencies * Correct WWW
Diffstat (limited to 'audio')
-rw-r--r--audio/csound6/Makefile139
-rw-r--r--audio/csound6/distinfo6
-rw-r--r--audio/csound6/files/patch-CMakeLists.txt84
-rw-r--r--audio/csound6/files/patch-InOut_rtalsa.c8
-rw-r--r--audio/csound6/files/patch-Opcodes_chua_ChuaOscillator.cpp12
-rw-r--r--audio/csound6/files/patch-Opcodes_stk_CMakeLists.txt11
-rw-r--r--audio/csound6/files/patch-Top_csound.c34
-rw-r--r--audio/csound6/files/patch-cmake_Modules_FindFAUST.cmake11
-rw-r--r--audio/csound6/files/patch-frontends_CsoundAC_ChordSpace.hpp19
-rw-r--r--audio/csound6/files/patch-frontends_CsoundAC_Composition.cpp37
-rw-r--r--audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.cpp89
-rw-r--r--audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.hpp13
-rw-r--r--audio/csound6/pkg-descr2
-rw-r--r--audio/csound6/pkg-plist99
14 files changed, 282 insertions, 282 deletions
diff --git a/audio/csound6/Makefile b/audio/csound6/Makefile
index a7917ee236d8..bcd68a0ffde2 100644
--- a/audio/csound6/Makefile
+++ b/audio/csound6/Makefile
@@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= csound
-PORTVERSION= 6.06.0
-PORTREVISION= 19
+DISTVERSION= 6.12.2
CATEGORIES= audio lang
PKGNAMESUFFIX= 6
DIST_SUBDIR= csound
@@ -14,69 +13,90 @@ COMMENT= Sound synthesizer
LICENSE= LGPL21+
LICENSE_FILE= ${WRKSRC}/COPYING
-BROKEN= fails to build
-
BUILD_DEPENDS= boost-libs>0:devel/boost-libs \
swig3.0:devel/swig30 \
gmm++>0:math/gmm++
LIB_DEPENDS= libsamplerate.so:audio/libsamplerate \
libsndfile.so:audio/libsndfile
-USES= alias bison cmake:outsource,noninja eigen:3 localbase python:2.7
+USES= alias bison cmake:outsource compiler:c++11-lib eigen:3 localbase ncurses python:2.7
# math/gmm++ requires c++11
USE_GITHUB= yes
-USE_CXXSTD= c++11
CMAKE_ARGS= -DBUILD_CSOUNDVST:BOOL=OFF \
- -DBUILD_JAVA_INTERFACE:BOOL=OFF \
- -DBUILD_P5GLOVE_OPCODES:BOOL=OFF \
-DBUILD_PD_CLASS:BOOL=OFF \
- -DBUILD_STK_OPCODES:BOOL=OFF \
- -DBUILD_TESTS:BOOL=OFF \
- -DBUILD_WIIMOTE_OPCODES:BOOL=OFF \
- -DPYTHON_MODULE_INSTALL_DIR:PATH="${PYTHONPREFIX_SITELIBDIR}"
+ -DPYTHON_MODULE_INSTALL_DIR:PATH="${PYTHONPREFIX_SITELIBDIR}" \
+ -DOPSYS:STRING="${OPSYS}"
+CMAKE_OFF= USE_ALSA BUILD_JAVA_INTERFACE BUILD_TESTS
USE_LDCONFIG= yes
SSP_UNSAFE= yes
BINARY_ALIAS= swig=swig3.0
+LDFLAGS+= -lexecinfo
SUB_FILES= pkg-message
CONFLICTS= csound-5.*
CONFLICTS_INSTALL= outguess-*
-OPTIONS_DEFINE= ALSA CURL DSSI FLTK FLUIDSYNTH HDF5 JACK LUA NLS \
- OPENMP OSC PNG PORTAUDIO PULSEAUDIO
+OPTIONS_DEFINE= CURL FLTK HDF5 NLS OPENMP PORTAUDIO PULSEAUDIO
+OPTIONS_GROUP= PLUGINS
+OPTIONS_GROUP_PLUGINS= BUCHLA CHUA DSSI EXCITER FAUST FLUIDSYNTH IMAGE JACK LUA LINALG OSC P5GLOVE PADSYNTH PLATEREV PVSGENDY SCANSYN SELECT SERIAL STACK STK WIIMOTE # Opcodes/CMakeLists.txt, Opcodes/stk/CMakeLists.txt
OPTIONS_DEFAULT= FLTK OPENMP
+OPTIONS_DEFAULT+= BUCHLA CHUA DSSI EXCITER FAUST FLUIDSYNTH IMAGE JACK OSC P5GLOVE PADSYNTH PLATEREV SCANSYN SELECT SERIAL STACK STK # for PLUGINS
OPTIONS_SUB= yes
-ALSA_DESC= Build ALSA I/O module
-ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib
-ALSA_CMAKE_OFF= -DUSE_ALSA:BOOL=OFF
-ALSA_PREVENTS= DSSI
+BUCHLA_DESC= Build the Buchla filter opcode
+BUCHLA_CMAKE_BOOL= BUILD_BUCHLA_OPCODES
+
+CHUA_DESC= Build the chua opcodes
+CHUA_CMAKE_BOOL= BUILD_CHUA_OPCODES
+
+CURL_CMAKE_BOOL= USE_CURL # see https://github.com/csound/csound/issues/1067
CURL_LIB_DEPENDS= libcurl.so:ftp/curl
-CURL_CMAKE_OFF= -DUSE_CURL:BOOL=OFF
-DSSI_DESC= Build DSSI/LADSPA host opcodes
+
+DSSI_DESC= Build DSSI opcodes
DSSI_BUILD_DEPENDS= dssi>0:audio/dssi
DSSI_LIB_DEPENDS= libdssialsacompat.so:audio/libdssialsacompat
DSSI_RUN_DEPENDS= dssi>0:audio/dssi
-DSSI_CMAKE_OFF= -DBUILD_DSSI_OPCODES:BOOL=OFF
+DSSI_CMAKE_BOOL= BUILD_DSSI_OPCODES
DSSI_CFLAGS= -isystem ${LOCALBASE}/include/dssi
-DSSI_PREVENTS= ALSA
+
+EXCITER_DESC= Build the exciter opcode
+EXCITER_CMAKE_BOOL= BUILD_EXCITER_OPCODES
+
FLTK_DESC= Build FLTK plugin and GUI
+FLTK_USE= XORG=ice,sm,x11,xext
FLTK_LIB_DEPENDS= libfltk.so:x11-toolkits/fltk
FLTK_CMAKE_ON= -DBUILD_WINSOUND:BOOL=ON
FLTK_CMAKE_OFF= -DBUILD_CSOUND_AC:BOOL=OFF \
-DBUILD_VIRTUAL_KEYBOARD:BOOL=OFF \
-DUSE_FLTK:BOOL=OFF
+
+FAUST_DESC= Build the Faust opcodes
+FAUST_USES= ssl
+FAUST_LLVM_VERSION= 60
+FAUST_BUILD_DEPENDS= faust>0:audio/faust
+FAUST_RUN_DEPENDS= faust>0:audio/faust \
+ llvm${FAUST_LLVM_VERSION}>0:devel/llvm${FAUST_LLVM_VERSION}
+FAUST_CMAKE_BOOL= BUILD_FAUST_OPCODES
+FAUST_CMAKE_ON= -DFAUST_LLVM_VERSION:STRING=${FAUST_LLVM_VERSION}
+
FLUIDSYNTH_DESC= Building FluidSynth opcodes
FLUIDSYNTH_LIB_DEPENDS= libfluidsynth.so:audio/fluidsynth
-FLUIDSYNTH_CMAKE_OFF= -DBUILD_FLUID_OPCODES:BOOL=OFF
+FLUIDSYNTH_CMAKE_BOOL= BUILD_FLUID_OPCODES
+
HDF5_DESC= Build HDF5 read/write opcodes
-HDF5_LIB_DEPENDS= libhdf5.so:science/hdf5
-HDF5_CMAKE_OFF= -DBUILD_HDF5_OPCODES:BOOL=OFF
-JACK_DESC= Build Jack I/O module and opcodes
+HDF5_LIB_DEPENDS= libhdf5.so:science/hdf5 \
+ libsz.so:science/szip
+HDF5_CMAKE_BOOL= BUILD_HDF5_OPCODES
+
+JACK_DESC= Build the JACK related opcodes
JACK_LIB_DEPENDS= libjack.so:audio/jack
-JACK_CMAKE_OFF= -DBUILD_JACK_OPCODES:BOOL=OFF \
- -DUSE_JACK:BOOL=OFF
+JACK_CMAKE_BOOL= BUILD_JACK_OPCODES USE_JACK
+
+LINALG_DESC= Build the linear algebra opcodes
+LINALG_CMAKE_BOOL= BUILD_LINEAR_ALGEBRA_OPCODES
+LINALG_BROKEN= see https://github.com/csound/csound/issues/1069
+
LUA_DESC= Build Lua Interface and opcodes
LUA_LIB_DEPENDS= libluajit-5.1.so:lang/luajit
LUA_CMAKE_OFF= -DBUILD_CSOUND_AC_LUA_INTERFACE:BOOL=OFF \
@@ -87,33 +107,58 @@ NLS_CMAKE_OFF= -DGETTEXT_MSGFMT_EXECUTABLE:FILEPATH="" \
-DGETTEXT_MSGMERGE_EXECUTABLE:FILEPATH="" \
-DLIBINTL_LIBRARY:FILEPATH="" \
-DUSE_GETTEXT:BOOL=OFF
-OPENMP_USES= compiler:gcc-c++11-lib
-OPENMP_USES_OFF= compiler:c++11-lib
-OPENMP_CMAKE_OFF= -DUSE_OPEN_MP:BOOL=OFF
+OPENMP_CMAKE_BOOL= USE_OPEN_MP
+
OSC_DESC= Build OSC opcodes
OSC_LIB_DEPENDS= liblo.so:audio/liblo
-OSC_CMAKE_OFF= -DBUILD_OSC_OPCODES:BOOL=OFF
-PNG_DESC= Build Image opcodes
-PNG_LIB_DEPENDS= libpng.so:graphics/png
-PNG_CMAKE_OFF= -DBUILD_IMAGE_OPCODES:BOOL=OFF
+OSC_CMAKE_BOOL= BUILD_OSC_OPCODES
+
+PADSYNTH_DESC= Build the Padsynth opcode
+PADSYNTH_CMAKE_BOOL= BUILD_PADSYNTH_OPCODES
+
+IMAGE_DESC= Build Image opcodes
+IMAGE_LIB_DEPENDS= libpng.so:graphics/png
+IMAGE_CMAKE_BOOL= BUILD_IMAGE_OPCODES
+
+P5GLOVE_DESC= Build PortAudio I/O module
+P5GLOVE_CMAKE_BOOL= BUILD_P5GLOVE_OPCODES
+
PORTAUDIO_DESC= Build PortAudio I/O module
PORTAUDIO_LIB_DEPENDS= libportaudio.so:audio/portaudio
-PORTAUDIO_CMAKE_OFF= -DUSE_PORTAUDIO:BOOL=OFF
+PORTAUDIO_CMAKE_BOOL= USE_PORTAUDIO
+
PULSEAUDIO_DESC= Build PulseAudio I/O module
PULSEAUDIO_LIB_DEPENDS= libpulse-simple.so:audio/pulseaudio
-PULSEAUDIO_CMAKE_OFF= -DUSE_PULSEAUDIO:BOOL=OFF
+PULSEAUDIO_CMAKE_BOOL= USE_PULSEAUDIO
+
+PLATEREV_DESC= Build the platerev opcode
+PLATEREV_CMAKE_BOOL= BUILD_PLATEREV_OPCODES
+
+PVSGENDY_DESC= Build the pvsgendy opcode
+PVSGENDY_CMAKE_BOOL= BUILD_PVSGENDY_OPCODE
+
+SCANSYN_DESC= Build the select opcodes
+SCANSYN_CMAKE_BOOL= BUILD_SCANSYN_OPCODES
+
+SELECT_DESC= Build the select opcode
+SELECT_CMAKE_BOOL= BUILD_SELECT_OPCODE
+
+SERIAL_DESC= Build the serial opcode
+SERIAL_CMAKE_BOOL= BUILD_SERIAL_OPCODES
+
+STACK_DESC= Build the stack opcodes
+STACK_CMAKE_BOOL= BUILD_STACK_OPCODES
+
+STK_DESC= Build the stk opcodes
+STK_CMAKE_BOOL= BUILD_STK_OPCODES
+STK_LIB_DEPENDS= libstk-4.6.0.so:audio/stk
+
+WIIMOTE_DESC= Build the Wiimote opcodes
+WIIMOTE_CMAKE_BOOL= BUILD_WIIMOTE_OPCODES
+WIIMOTE_BROKEN= Need to port wiiuse: https://github.com/rpavlik/wiiuse
post-patch:
@${REINPLACE_CMD} -e \
- '/-O3/s|^|#| ; \
- /PYTHON_MODULE_INSTALL_DIR/s|^|#| ; \
- /CMAKE_SYSTEM_NAME/s|"Linux"|"${OPSYS}"| ; \
- s|(LIBINTL_LIBRARY OR LINUX)|(LIBINTL_LIBRARY)| ; \
- s|(NOT LINUX)|(LINUX)| ; \
- s|-D_GNU_SOURCE|| ; \
- s| dl)|)|' \
- ${WRKSRC}/CMakeLists.txt
- @${REINPLACE_CMD} -e \
's|/usr/local|${LOCALBASE}|' \
${WRKSRC}/InOut/CMakeLists.txt
@${REINPLACE_CMD} -e \
@@ -124,7 +169,7 @@ post-patch:
${WRKSRC}/Opcodes/CMakeLists.txt
@${REINPLACE_CMD} -e \
'/CMAKE_SYSTEM_NAME/s|"Linux"|"${OPSYS}"|' \
- ${WRKSRC}/frontends/CMakeLists.txt
+ ${WRKSRC}/Frontends/CMakeLists.txt
@${REINPLACE_CMD} -e \
's| mixer)| csmixer)|' \
${WRKSRC}/util/CMakeLists.txt
diff --git a/audio/csound6/distinfo b/audio/csound6/distinfo
index d7675a78e464..02186cfda641 100644
--- a/audio/csound6/distinfo
+++ b/audio/csound6/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1542475461
-SHA256 (csound/csound-csound-6.06.0_GH0.tar.gz) = ce01dbf249eb6cf27e3090b8d9aa7d779256a364707ce0b81f7545dc168d9d50
-SIZE (csound/csound-csound-6.06.0_GH0.tar.gz) = 33089325
+TIMESTAMP = 1542473401
+SHA256 (csound/csound-csound-6.12.2_GH0.tar.gz) = 39f4872b896eb1cbbf596fcacc0f2122fd3e5ebbb5cec14a81b4207d6b8630ff
+SIZE (csound/csound-csound-6.12.2_GH0.tar.gz) = 26297850
diff --git a/audio/csound6/files/patch-CMakeLists.txt b/audio/csound6/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..2d6f0f93e3dd
--- /dev/null
+++ b/audio/csound6/files/patch-CMakeLists.txt
@@ -0,0 +1,84 @@
+--- CMakeLists.txt.orig 2018-11-07 14:05:23 UTC
++++ CMakeLists.txt
+@@ -164,8 +164,8 @@ endif()
+
+ # set -Werror if in Debug configuration
+ if(NOT MSVC AND NOT WASM)
+-set(CMAKE_CXX_FLAGS_RELEASE "-O3 ")
+-set(CMAKE_C_FLAGS_RELEASE "-O3 ")
++#set(CMAKE_CXX_FLAGS_RELEASE "-O3 ")
++#set(CMAKE_C_FLAGS_RELEASE "-O3 ")
+ if(${CMAKE_BUILD_TYPE} MATCHES "Debug")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror -Wno-missing-field-initializers")
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Werror -Wno-missing-field-initializers")
+@@ -206,7 +206,7 @@ execute_process (
+ OUTPUT_VARIABLE PYTHON_USER_SITE_PACKAGES
+ )
+
+-SET(PYTHON_MODULE_INSTALL_DIR ${PYTHON_USER_SITE_PACKAGES} CACHE PATH "Python module install dir")
++#SET(PYTHON_MODULE_INSTALL_DIR ${PYTHON_USER_SITE_PACKAGES} CACHE PATH "Python module install dir")
+
+ set(JAVA_MODULE_INSTALL_DIR ${LIBRARY_INSTALL_DIR} CACHE PATH "Java module install dir")
+ set(LUA_MODULE_INSTALL_DIR ${LIBRARY_INSTALL_DIR} CACHE PATH "Lua module install dir")
+@@ -373,12 +373,12 @@ endif()
+
+ endif(WIN32)
+
+-if(APPLE)
++if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "${OPSYS}")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
+ set_target_properties(${CSOUNDLIB} PROPERTIES CXX_COMPILE_FLAGS "-std=c++11")
+ endif()
+
+-if(CMAKE_SYSTEM_NAME MATCHES "Linux")
++if(CMAKE_SYSTEM_NAME MATCHES "${OPSYS}")
+ set(LINUX YES)
+ else()
+ set(LINUX NO)
+@@ -527,15 +527,17 @@ find_package(FLTK )
+ # LIST_REPLACE(FLTK_LIBRARIES 2 "fltk_images_SHARED")
+ # endif()
+ #endif()
+-find_package(FAUST)
+-find_package(Java)
+-find_package(JNI)
++if (BUILD_FAUST_OPCODES)
++ find_package(FAUST)
++endif()
++#find_package(Java)
++#find_package(JNI)
+ find_package(LIBLO)
+ find_package(LUAJIT)
+ find_package(MUSICXML)
+ find_package(PORTSMF)
+ find_package(PythonLibs 2.7)
+-if(NOT STK_LOCAL)
++if(BUILD_STK_OPCODES AND NOT STK_LOCAL)
+ find_package(STK)
+ endif()
+ find_package(SWIG)
+@@ -1245,11 +1247,11 @@ if(CURL_FOUND)
+ endif()
+
+ # Linux does not have a separate libintl, it is part of libc
+-set(LIBINTL_AVAIL (LIBINTL_LIBRARY OR LINUX))
++set(LIBINTL_AVAIL (LIBINTL_LIBRARY))
+ check_deps(USE_GETTEXT LIBINTL_HEADER LIBINTL_AVAIL GETTEXT_MSGFMT_EXECUTABLE)
+ if(USE_GETTEXT)
+ message(STATUS "Using GNU gettext.")
+- if(NOT LINUX)
++ if(LINUX)
+ list(APPEND libcsound_LIBS ${LIBINTL_LIBRARY})
+ endif()
+ list(APPEND libcsound_CFLAGS -DGNU_GETTEXT)
+@@ -1269,8 +1271,8 @@ endif()
+
+ if(LINUX)
+ message(STATUS "Building on Linux.")
+- add_definitions(-DLINUX -DPIPES -DNO_FLTK_THREADS -D_GNU_SOURCE -DHAVE_SOCKETS)
+- list(APPEND libcsound_LIBS m dl)
++ add_definitions(-DLINUX -DPIPES -DNO_FLTK_THREADS -DHAVE_SOCKETS)
++ list(APPEND libcsound_LIBS m)
+
+ find_library(LIBRT_LIBRARY rt)
+
diff --git a/audio/csound6/files/patch-InOut_rtalsa.c b/audio/csound6/files/patch-InOut_rtalsa.c
index 7b13e67f0a43..11f938a16a08 100644
--- a/audio/csound6/files/patch-InOut_rtalsa.c
+++ b/audio/csound6/files/patch-InOut_rtalsa.c
@@ -1,14 +1,14 @@
---- InOut/rtalsa.c.orig 2015-09-29 11:13:27 UTC
+--- InOut/rtalsa.c.orig 2018-11-07 14:05:23 UTC
+++ InOut/rtalsa.c
@@ -23,6 +23,7 @@
- 02111-1307 USA
+ 02110-1301 USA
*/
+/*
#ifndef _ISOC99_SOURCE
#define _ISOC99_SOURCE 1
#endif
-@@ -32,6 +33,7 @@
+@@ -36,6 +37,7 @@
#ifndef _BSD_SOURCE
#define _BSD_SOURCE 1
#endif
@@ -16,7 +16,7 @@
#include "csdl.h"
-@@ -50,6 +52,8 @@
+@@ -54,6 +56,8 @@
#include <signal.h>
#include <sys/mman.h>
#include <sys/resource.h>
diff --git a/audio/csound6/files/patch-Opcodes_chua_ChuaOscillator.cpp b/audio/csound6/files/patch-Opcodes_chua_ChuaOscillator.cpp
deleted file mode 100644
index 107c7065cc5c..000000000000
--- a/audio/csound6/files/patch-Opcodes_chua_ChuaOscillator.cpp
+++ /dev/null
@@ -1,12 +0,0 @@
---- Opcodes/chua/ChuaOscillator.cpp.orig 2015-09-29 11:13:27 UTC
-+++ Opcodes/chua/ChuaOscillator.cpp
-@@ -117,8 +117,8 @@
- // d = sys_variables(12);
- // gnor = a*(x.^3) + b*(x.^2) + c*x + d;
-
--#include <OpcodeBase.hpp>
- #include <boost/numeric/ublas/vector.hpp>
-+#include <OpcodeBase.hpp>
- using namespace boost::numeric;
- #include <cmath>
-
diff --git a/audio/csound6/files/patch-Opcodes_stk_CMakeLists.txt b/audio/csound6/files/patch-Opcodes_stk_CMakeLists.txt
new file mode 100644
index 000000000000..f7b69b36bd55
--- /dev/null
+++ b/audio/csound6/files/patch-Opcodes_stk_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- Opcodes/stk/CMakeLists.txt.orig 2018-11-17 19:16:54 UTC
++++ Opcodes/stk/CMakeLists.txt
+@@ -4,7 +4,7 @@ if(WIN32)
+ cmake_policy(SET CMP0060 NEW)
+ endif()
+
+-if(NOT STK_LOCAL)
++if(BUILD_STK_OPCODES AND NOT STK_LOCAL)
+ find_package(STK)
+ endif()
+
diff --git a/audio/csound6/files/patch-Top_csound.c b/audio/csound6/files/patch-Top_csound.c
index 3d417d6ace46..e5b3f6e4fd2a 100644
--- a/audio/csound6/files/patch-Top_csound.c
+++ b/audio/csound6/files/patch-Top_csound.c
@@ -1,21 +1,31 @@
---- Top/csound.c.orig 2015-09-29 11:13:27 UTC
+--- Top/csound.c.orig 2018-11-07 14:05:23 UTC
+++ Top/csound.c
-@@ -60,10 +60,13 @@
- #include "cs_par_dispatch.h"
- #include "csound_orc_semantics.h"
+@@ -60,10 +60,14 @@
+ //#include "cs_par_dispatch.h"
+ #include "find_opcode.h"
--#if defined(linux) || defined(__HAIKU__) || defined(__EMSCRIPTEN__)
-+#if defined(linux) || defined(__HAIKU__) || defined(__FreeBSD__) || defined(__EMSCRIPTEN__)
+-#if defined(linux)||defined(__HAIKU__)|| defined(__EMSCRIPTEN__)||defined(__CYGWIN__)
++#if defined(linux) || defined(__FreeBSD__) || defined(__HAIKU__)|| defined(__EMSCRIPTEN__)||defined(__CYGWIN__)
#define PTHREAD_SPINLOCK_INITIALIZER 0
#endif
+#if defined(__FreeBSD__)
+#include <sys/sysctl.h>
+#endif
- #if defined(USE_OPENMP)
- #include <omp.h>
- #endif /* USE_OPENMP */
-@@ -3510,7 +3513,7 @@ void csoundNotifyFileOpened(CSOUND* csou
++
+ #include "csound_standard_types.h"
+
+ #include "csdebug.h"
+@@ -405,7 +409,7 @@ static const CSOUND cenviron_ = {
+ rewriteheader,
+ csoundLoadSoundFile,
+ fdrecord,
+- fdclose,
++ fd__close,
+ csoundCreateFileHandle,
+ csoundGetFileName,
+ csoundFileClose,
+@@ -3755,7 +3759,7 @@ void csoundNotifyFileOpened(CSOUND* csou
/* ------------------------------------ */
#if defined(HAVE_RDTSC)
@@ -24,7 +34,7 @@
#undef HAVE_RDTSC
#endif
#endif
-@@ -3523,6 +3526,13 @@ static double timeResolutionSeconds = -1
+@@ -3768,6 +3772,13 @@ static double timeResolutionSeconds = -1
static int getTimeResolution(void)
{
#if defined(HAVE_RDTSC)
@@ -38,7 +48,7 @@
FILE *f;
char buf[256];
-@@ -3558,9 +3568,14 @@ static int getTimeResolution(void)
+@@ -3803,9 +3814,14 @@ static int getTimeResolution(void)
}
}
fclose(f);
diff --git a/audio/csound6/files/patch-cmake_Modules_FindFAUST.cmake b/audio/csound6/files/patch-cmake_Modules_FindFAUST.cmake
new file mode 100644
index 000000000000..40e45b4557cc
--- /dev/null
+++ b/audio/csound6/files/patch-cmake_Modules_FindFAUST.cmake
@@ -0,0 +1,11 @@
+--- cmake/Modules/FindFAUST.cmake.orig 2018-11-17 16:56:13 UTC
++++ cmake/Modules/FindFAUST.cmake
+@@ -27,7 +27,7 @@ if(FAUST_FOUND)
+ # This is a static build of faust, hence
+ # we have to add all the LLVM flags...
+
+- find_program(LLVM_CONFIG llvm-config HINTS /usr/bin /usr/local/bin /usr/local/opt/llvm/bin)
++ find_program(LLVM_CONFIG llvm-config${FAUST_LLVM_VERSION} HINTS /usr/bin /usr/local/bin /usr/local/opt/llvm/bin)
+ if(NOT LLVM_CONFIG)
+ message(FATAL_ERROR "Using a static Faust library requires LLVM tooling to be present in the path")
+ endif()
diff --git a/audio/csound6/files/patch-frontends_CsoundAC_ChordSpace.hpp b/audio/csound6/files/patch-frontends_CsoundAC_ChordSpace.hpp
deleted file mode 100644
index 0471a156f344..000000000000
--- a/audio/csound6/files/patch-frontends_CsoundAC_ChordSpace.hpp
+++ /dev/null
@@ -1,19 +0,0 @@
---- frontends/CsoundAC/ChordSpace.hpp.orig 2015-09-29 11:13:28 UTC
-+++ frontends/CsoundAC/ChordSpace.hpp
-@@ -29,6 +29,7 @@
- #include <climits>
- #include <cmath>
- #include <cstdarg>
-+#include <cstdio>
- #include <eigen3/Eigen/Dense>
- #include "Event.hpp"
- #include <iostream>
-@@ -554,7 +555,7 @@ public:
- char buffer[0x1000];
- std::stringstream stream;
- for (size_t voice = 0; voice < voices(); ++voice) {
-- std::snprintf(buffer, 0x100, "%12.7f", getPitch(voice));
-+ snprintf(buffer, 0x100, "%12.7f", getPitch(voice));
- if (voice > 0) {
- stream << " ";
- }
diff --git a/audio/csound6/files/patch-frontends_CsoundAC_Composition.cpp b/audio/csound6/files/patch-frontends_CsoundAC_Composition.cpp
deleted file mode 100644
index fa72c72c0d05..000000000000
--- a/audio/csound6/files/patch-frontends_CsoundAC_Composition.cpp
+++ /dev/null
@@ -1,37 +0,0 @@
---- frontends/CsoundAC/Composition.cpp.orig 2015-09-29 11:13:28 UTC
-+++ frontends/CsoundAC/Composition.cpp
-@@ -22,6 +22,7 @@
- #endif
- #include "Composition.hpp"
- #include "System.hpp"
-+#include <cstdio>
- #include <cstdlib>
- #include <map>
-
-@@ -289,7 +290,7 @@ namespace csound
- int Composition::normalizeOutputSoundfile(double levelDb)
- {
- char buffer[0x100];
-- std::snprintf(buffer,
-+ snprintf(buffer,
- 0x100,
- "sox %s -V3 -b 32 -e floating-point %s gain -n %f\n",
- getOutputSoundfileName().c_str(),
-@@ -307,7 +308,7 @@ namespace csound
- int Composition::translateToCdAudio(double levelDb)
- {
- char buffer[0x100];
-- std::snprintf(buffer, 0x100, "sox %s -V3 -b 16 %s gain -n %f rate 44100\n",
-+ snprintf(buffer, 0x100, "sox %s -V3 -b 16 %s gain -n %f rate 44100\n",
- getOutputSoundfileName().c_str(),
- getCdSoundfileName().c_str(),
- levelDb);
-@@ -323,7 +324,7 @@ namespace csound
- int Composition::translateToMp3(double bitrate, double levelDb)
- {
- char buffer[0x100];
-- std::snprintf(buffer,
-+ snprintf(buffer,
- 0x100,
- "lame --verbose --disptime 2 --nohist --preset cd --tt %s --ta %s --tl %s --tc %s %s %s\n",
- getTitle().c_str(),
diff --git a/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.cpp b/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.cpp
deleted file mode 100644
index 46802038c0f3..000000000000
--- a/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.cpp
+++ /dev/null
@@ -1,89 +0,0 @@
---- frontends/CsoundAC/Counterpoint.cpp.orig 2015-09-29 11:13:28 UTC
-+++ frontends/CsoundAC/Counterpoint.cpp
-@@ -217,8 +217,8 @@ void Counterpoint::toCsoundScore(std::st
- delete uniform_real_generator;
- }
- int Counterpoint::ABS(int i) {if (i < 0) return(-i); else return(i);}
-- int Counterpoint::MIN(int a, int b) {if (a < b) return(a); else return(b);}
-- int Counterpoint::MAX(int a, int b) {if (a > b) return(a); else return(b);}
-+ int Counterpoint::IMIN(int a, int b) {if (a < b) return(a); else return(b);}
-+ int Counterpoint::IMAX(int a, int b) {if (a > b) return(a); else return(b);}
- void Counterpoint::ARRBLT(int *dest, int *source, int num) {int i; for (i=0;i<num;i++) dest[i]=source[i];} /* SAIL p51 */
-
- int Counterpoint::InMode(int Pitch, int Mode)
-@@ -294,8 +294,8 @@ void Counterpoint::toCsoundScore(std::st
- for (i=1;i<Cn;i++)
- {
- pit=Us(i,v);
-- Minp=MIN(Minp,pit);
-- Maxp=MAX(Maxp,pit);
-+ Minp=IMIN(Minp,pit);
-+ Maxp=IMAX(Maxp,pit);
- }
- return(Maxp-Minp);
- }
-@@ -316,7 +316,7 @@ void Counterpoint::toCsoundScore(std::st
- {
- int j,LowestPitch;
- LowestPitch=Cantus(Cn,v);
-- for (j=1;j<v;j++) LowestPitch=MIN(LowestPitch,Other(Cn,v,j));
-+ for (j=1;j<v;j++) LowestPitch=IMIN(LowestPitch,Other(Cn,v,j));
- return(LowestPitch);
- }
-
-@@ -993,7 +993,7 @@ void Counterpoint::toCsoundScore(std::st
- /* slightly frown upon leap back in the opposite direction */
- if ((Cn>2) && ((ASkip(MelInt)) && ((ASkip(LastMelInt)) && (!(SameDir)))))
- {
-- Val += (MAX(0,((ABS(MelInt)+ABS(LastMelInt))-8)));
-+ Val += (IMAX(0,((ABS(MelInt)+ABS(LastMelInt))-8)));
- if ((Cn>3) && (ASkip(LastCp2-LastCp3))) Val += ThreeSkipsPenalty;
- }
-
-@@ -1009,7 +1009,7 @@ void Counterpoint::toCsoundScore(std::st
- if ((Us(k,v)-Cantus(k,v))*(Us(k-1,v)-Cantus(k-1,v)) < 0) Cross++;
- }
- }
-- if (Cross > 0) Val += (MAX(0,((Cross-2)*3)));
-+ if (Cross > 0) Val += (IMAX(0,((Cross-2)*3)));
-
- /* don't repeat note on upbeat */
- if (UpBeat(Cn,v) && (MelInt == Unison)) Val += RepetitionOnUpbeatPenalty;
-@@ -1107,7 +1107,7 @@ void Counterpoint::toCsoundScore(std::st
- }
- }
- BestFitPenalty=CurrentPenalty+Penalty;
-- MaxPenalty=MIN(int(BestFitPenalty*PenaltyRatio),MaxPenalty);
-+ MaxPenalty=IMIN(int(BestFitPenalty*PenaltyRatio),MaxPenalty);
- /* AllDone=1; */
- Fits[2]=Fits[1]; Fits[1]=Fits[0]; Fits[0]=BestFitPenalty;
- for (v=1;v<=v1;v++)
-@@ -1164,7 +1164,7 @@ void Counterpoint::toCsoundScore(std::st
- {
- for (i=1;i<=NumParts;i++) Pens[x-i]=Is[i];
- }
-- else NewLim=MIN(NewLim,penalty);
-+ else NewLim=IMIN(NewLim,penalty);
- }
- }
- }
-@@ -1196,7 +1196,7 @@ void Counterpoint::toCsoundScore(std::st
- for (i=0;i<=NumParts;i++)
- {
- OurTime=Onset(VIndex(CurTime,i)+1,i);
-- if (OurTime != 0) NextTime=MIN(NextTime,OurTime);
-+ if (OurTime != 0) NextTime=IMIN(NextTime,OurTime);
- }
- for (i=1;i<=NumParts;i++)
- {
-@@ -1289,8 +1289,8 @@ void Counterpoint::toCsoundScore(std::st
- {
- int i;
- i=(int)(RANDOM(10.0));
-- if (CurRhy(i) > CurRhy(MAX(1,(i-1)))) return(MAX(1,(i-1)));
-- if (CurRhy(i) <= CurRhy(MIN(9,(i+1)))) return(MIN(9,(i+1)));
-+ if (CurRhy(i) > CurRhy(IMAX(1,(i-1)))) return(IMAX(1,(i-1)));
-+ if (CurRhy(i) <= CurRhy(IMIN(9,(i+1)))) return(IMIN(9,(i+1)));
- return(i);
- }
-
diff --git a/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.hpp b/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.hpp
deleted file mode 100644
index 6a4dda8f0477..000000000000
--- a/audio/csound6/files/patch-frontends_CsoundAC_Counterpoint.hpp
+++ /dev/null
@@ -1,13 +0,0 @@
---- frontends/CsoundAC/Counterpoint.hpp.orig 2015-09-29 11:13:28 UTC
-+++ frontends/CsoundAC/Counterpoint.hpp
-@@ -102,8 +102,8 @@ public:
- Counterpoint();
- virtual ~Counterpoint();
- int ABS(int i);
-- int MIN(int a, int b);
-- int MAX(int a, int b);
-+ int IMIN(int a, int b);
-+ int IMAX(int a, int b);
- void ARRBLT(int *dest, int *source, int num);
- enum
- {
diff --git a/audio/csound6/pkg-descr b/audio/csound6/pkg-descr
index 368e0552a97a..11619737c6b7 100644
--- a/audio/csound6/pkg-descr
+++ b/audio/csound6/pkg-descr
@@ -18,4 +18,4 @@ for a 1 million voice granular texture!
Have you ever dreamed of sounds such as these? Well in Csound you can.
And in Csound these dreams can come true!
-WWW: http://www.csounds.com/
+WWW: https://csound.com/
diff --git a/audio/csound6/pkg-plist b/audio/csound6/pkg-plist
index af7398d52042..ce437a000083 100644
--- a/audio/csound6/pkg-plist
+++ b/audio/csound6/pkg-plist
@@ -33,6 +33,7 @@ bin/srconv
include/csound/CppSound.hpp
include/csound/CsoundFile.hpp
include/csound/OpcodeBase.hpp
+include/csound/arrays.h
include/csound/cfgvar.h
include/csound/csPerfThread.hpp
include/csound/cs_par_structs.h
@@ -44,12 +45,15 @@ include/csound/csound.hpp
include/csound/csoundCore.h
include/csound/csound_data_structures.h
include/csound/csound_standard_types.h
+include/csound/csound_threaded.hpp
include/csound/csound_type_system.h
include/csound/cwindow.h
include/csound/filebuilding.h
include/csound/float-version.h
include/csound/interlocks.h
+include/csound/modload.h
include/csound/msg_attr.h
+include/csound/plugin.h
include/csound/pools.h
include/csound/pstream.h
include/csound/pvfileio.h
@@ -57,47 +61,54 @@ include/csound/soundio.h
include/csound/sysdep.h
include/csound/text.h
include/csound/version.h
-lib/csound/plugins-6.0/csladspa.so
-%%LUA%%lib/csound/plugins-6.0/libLuaCsound.so
-lib/csound/plugins-6.0/libampmidid.so
-lib/csound/plugins-6.0/libbuchla.so
-lib/csound/plugins-6.0/libcellular.so
-lib/csound/plugins-6.0/libchua.so
-lib/csound/plugins-6.0/libcontrol.so
-lib/csound/plugins-6.0/libcs_date.so
-lib/csound/plugins-6.0/libdoppler.so
-%%DSSI%%lib/csound/plugins-6.0/libdssi4cs.so
-lib/csound/plugins-6.0/libexciter.so
-lib/csound/plugins-6.0/libfareygen.so
-%%FLUIDSYNTH%%lib/csound/plugins-6.0/libfluidOpcodes.so
-lib/csound/plugins-6.0/libfractalnoise.so
-lib/csound/plugins-6.0/libframebuffer.so
-%%HDF5%%lib/csound/plugins-6.0/libhdf5.so
-%%PNG%%lib/csound/plugins-6.0/libimage.so
-lib/csound/plugins-6.0/libipmidi.so
-%%JACK%%lib/csound/plugins-6.0/libjackTransport.so
-%%JACK%%lib/csound/plugins-6.0/libjacko.so
-lib/csound/plugins-6.0/liblinear_algebra.so
-lib/csound/plugins-6.0/libmixer.so
-%%OSC%%lib/csound/plugins-6.0/libosc.so
-lib/csound/plugins-6.0/libpadsynth.so
-lib/csound/plugins-6.0/libplaterev.so
-lib/csound/plugins-6.0/libpy.so
-%%ALSA%%lib/csound/plugins-6.0/librtalsa.so
-%%JACK%%lib/csound/plugins-6.0/librtjack.so
-%%PORTAUDIO%%lib/csound/plugins-6.0/librtpa.so
-%%PULSEAUDIO%%lib/csound/plugins-6.0/librtpulse.so
-lib/csound/plugins-6.0/libscansyn.so
-lib/csound/plugins-6.0/libserial.so
-lib/csound/plugins-6.0/libsignalflowgraph.so
-lib/csound/plugins-6.0/libstdutil.so
-lib/csound/plugins-6.0/libsystem_call.so
-lib/csound/plugins-6.0/liburandom.so
-%%FLTK%%lib/csound/plugins-6.0/libvirtual.so
-%%FLTK%%lib/csound/plugins-6.0/libwidgets.so
-%%FLTK%%lib/libCsoundAC.so
+lib/csound/plugins64-6.0/libampmidid.so
+lib/csound/plugins64-6.0/libarrayops.so
+lib/csound/plugins64-6.0/libbeosc.so
+%%BUCHLA%%lib/csound/plugins64-6.0/libbuchla.so
+lib/csound/plugins64-6.0/libcellular.so
+%%CHUA%%lib/csound/plugins64-6.0/libchua.so
+lib/csound/plugins64-6.0/libcontrol.so
+lib/csound/plugins64-6.0/libcs_date.so
+lib/csound/plugins64-6.0/libdoppler.so
+%%DSSI%%lib/csound/plugins64-6.0/libdssi4cs.so
+lib/csound/plugins64-6.0/libemugens.so
+%%EXCITER%%lib/csound/plugins64-6.0/libexciter.so
+lib/csound/plugins64-6.0/libfareygen.so
+%%FAUST%%lib/csound/plugins64-6.0/libfaustcsound.so
+%%FLUIDSYNTH%%lib/csound/plugins64-6.0/libfluidOpcodes.so
+lib/csound/plugins64-6.0/libfractalnoise.so
+lib/csound/plugins64-6.0/libframebuffer.so
+lib/csound/plugins64-6.0/libftsamplebank.so
+lib/csound/plugins64-6.0/libgetftargs.so
+%%IMAGE%%lib/csound/plugins64-6.0/libimage.so
+lib/csound/plugins64-6.0/libipmidi.so
+%%JACK%%lib/csound/plugins64-6.0/libjackTransport.so
+%%JACK%%lib/csound/plugins64-6.0/libjacko.so
+%%HDF5%%lib/csound/plugins64-6.0/libhdf5ops.so
+lib/csound/plugins64-6.0/libliveconv.so
+lib/csound/plugins64-6.0/libmixer.so
+%%OSC%%lib/csound/plugins64-6.0/libosc.so
+%%PADSYNTH%%lib/csound/plugins64-6.0/libpadsynth.so
+%%PLATEREV%%lib/csound/plugins64-6.0/libplaterev.so
+lib/csound/plugins64-6.0/libpvsops.so
+lib/csound/plugins64-6.0/libpy.so
+lib/csound/plugins64-6.0/libquadbezier.so
+%%JACK%%lib/csound/plugins64-6.0/librtjack.so
+%%PORTAUDIO%%lib/csound/plugins64-6.0/librtpa.so
+%%PULSEAUDIO%%lib/csound/plugins64-6.0/librtpulse.so
+%%SCANSYN%%lib/csound/plugins64-6.0/libscansyn.so
+lib/csound/plugins64-6.0/libscugens.so
+%%SELECT%%lib/csound/plugins64-6.0/libselect.so
+%%SERIAL%%lib/csound/plugins64-6.0/libserial.so
+lib/csound/plugins64-6.0/libsignalflowgraph.so
+%%STACK%%lib/csound/plugins64-6.0/libstackops.so
+lib/csound/plugins64-6.0/libstdutil.so
+%%STK%%lib/csound/plugins64-6.0/libstkops.so
+lib/csound/plugins64-6.0/libsystem_call.so
+lib/csound/plugins64-6.0/liburandom.so
+%%FLTK%%lib/csound/plugins64-6.0/libvirtual.so
+%%FLTK%%lib/csound/plugins64-6.0/libwidgets.so
%%FLTK%%lib/libCsoundAC.so.6
-%%FLTK%%lib/libCsoundAC.so.6.0
lib/libcsnd6.so
lib/libcsnd6.so.6
lib/libcsnd6.so.6.0
@@ -105,16 +116,14 @@ lib/libcsound64.so
lib/libcsound64.so.6
lib/libcsound64.so.6.0
%%LUA%%lib/luaCsnd6.so
-%%LUA%%lib/luaCsoundAC.so
-%%FLTK%%%%PYTHON_SITELIBDIR%%/CsoundAC.py
-%%FLTK%%%%PYTHON_SITELIBDIR%%/_CsoundAC.so
%%PYTHON_SITELIBDIR%%/_csnd6.so
%%PYTHON_SITELIBDIR%%/csnd6.py
-%%PYTHON_SITELIBDIR%%/icsound.py
+%%PYTHON_SITELIBDIR%%/ctcsound.py
+share/cmake/Csound/FindCsound.cmake
%%NLS%%share/locale/de/LC_MESSAGES/csound6.mo
%%NLS%%share/locale/en_US/LC_MESSAGES/csound6.mo
+%%NLS%%share/locale/es/LC_MESSAGES/csound6.mo
%%NLS%%share/locale/es_CO/LC_MESSAGES/csound6.mo
%%NLS%%share/locale/fr/LC_MESSAGES/csound6.mo
%%NLS%%share/locale/it/LC_MESSAGES/csound6.mo
-%%NLS%%share/locale/ro/LC_MESSAGES/csound6.mo
%%NLS%%share/locale/ru/LC_MESSAGES/csound6.mo