SHA256
1
0
forked from pool/csound

Accepting request 819908 from multimedia:apps

@babelworx Removed unused util/new_srconv.c from sources to fix licensing.

OBS-URL: https://build.opensuse.org/request/show/819908
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/csound?expand=0&rev=30
This commit is contained in:
Dominique Leuenberger 2020-07-10 12:12:35 +00:00 committed by Git OBS Bridge
commit 9d14bec49a
10 changed files with 86 additions and 139 deletions

22
_service Normal file
View File

@ -0,0 +1,22 @@
<!-- Downloads csound git git master -->
<services>
<service name="tar_scm" mode="disabled">
<param name="url">https://github.com/csound/csound.git</param>
<param name="scm">git</param>
<param name="submodules">disable</param>
<param name="package-meta">no</param>
<param name="changesgenerate">enable</param>
<param name="exclude">.git</param>
<param name="exclude">Opcodes/scansyn*</param>
<param name="exclude">Android</param>
<param name="exclude">util/new_srconv.c</param>
<param name="versionformat">6.14.0+git%cd</param>
<param name="filename">csound</param>
<param name="revision">0dad8304c78efba48b4f405f4757f3e0a7e339c0</param>
</service>
<service name="recompress" mode="disabled">
<param name="file">*.tar</param>
<param name="compression">xz</param>
</service>
<service name="set_version" mode="disabled"/>
</services>

4
_servicedata Normal file
View File

@ -0,0 +1,4 @@
<servicedata>
<service name="tar_scm">
<param name="url">https://github.com/csound/csound.git</param>
<param name="changesrevision">0dad8304c78efba48b4f405f4757f3e0a7e339c0</param></service></servicedata>

View File

@ -1,13 +1,13 @@
Index: csound-6.12.2/Top/csound.c
Index: csound-6.14.0/Top/csound.c
===================================================================
--- csound-6.12.2.orig/Top/csound.c 2018-11-07 16:05:23.000000000 +0200
+++ csound-6.12.2/Top/csound.c 2019-04-05 15:32:03.893551257 +0200
@@ -3443,7 +3443,7 @@ PUBLIC void csoundReset(CSOUND *csound)
csoundCreateGlobalVariable(csound, "_RTAUDIO", (size_t) max_len);
s = csoundQueryGlobalVariable(csound, "_RTAUDIO");
#ifndef LINUX
- strcpy(s, "PortAudio");
+ strcpy(s, "pulse");
--- csound-6.14.0.orig/Top/csound.c 2020-06-02 11:58:24.594002125 +0200
+++ csound-6.14.0/Top/csound.c 2020-06-02 12:02:34.339852882 +0200
@@ -3456,7 +3456,7 @@ PUBLIC void csoundReset(CSOUND *csound)
#ifdef __HAIKU__
strcpy(s, "haiku");
#else
- strcpy(s, "PortAudio");
+ strcpy(s, "pulse");
#endif
#else
strcpy(s, "alsa");
#endif

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b8ec07b486decbd3edcc442554b73befe7972c81e1723047f5c02a2ff9215d30
size 20890172

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4224e01c7a46a25fbe7eedf19d1385e94768b64b9d780572fd7303d07ec48f50
size 22245236

View File

@ -1,8 +1,8 @@
Index: csound-6.12.2/util/CMakeLists.txt
Index: csound-6.14.0/util/CMakeLists.txt
===================================================================
--- csound-6.12.2.orig/util/CMakeLists.txt 2018-11-07 16:05:23.000000000 +0200
+++ csound-6.12.2/util/CMakeLists.txt 2019-06-26 09:45:26.891391042 +0200
@@ -1,62 +1,62 @@
--- csound-6.14.0.orig/util/CMakeLists.txt 2020-06-02 12:05:59.179933351 +0200
+++ csound-6.14.0/util/CMakeLists.txt 2020-06-02 12:11:39.845373490 +0200
@@ -1,54 +1,54 @@
-# UTILITY PLUGIN AND PROGRAMS
-
-set(stdutil_SRCS
@ -13,16 +13,11 @@ Index: csound-6.12.2/util/CMakeLists.txt
- sndinfo.c srconv.c std_util.c xtrct.c
- SDIF/sdif.c)
-
-if(MSVC)
- make_plugin(stdutil "${stdutil_SRCS}" )
- target_link_libraries(stdutil ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
-elseif(WIN32)
- make_plugin(stdutil "${stdutil_SRCS}" m
- ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
-else()
- make_plugin(stdutil "${stdutil_SRCS}" m ${LIBSNDFILE_LIBRARY})
-if(MSVC)
- set(LIBSNDFILE_LIBRARY sndfile-static)
-endif()
-
-make_plugin(stdutil "${stdutil_SRCS}" ${MATH_LIBRARY} ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
-add_dependency_to_framework(stdutil ${LIBSNDFILE_LIBRARY})
-
-if(BUILD_UTILITIES)
@ -36,12 +31,9 @@ Index: csound-6.12.2/util/CMakeLists.txt
- make_utility(het_import heti_main.c)
- make_utility(hetro het_main.c)
- make_utility(lpanal lpc_main.c)
- make_utility(lpc_export lpcx_main.c)
- make_utility(lpc_import lpci_main.c)
- make_executable(mixer-bin mixer_main.c "${CSOUNDLIB}" mixer)
- if(LINUX)
- target_link_libraries(mixer-bin m)
- endif()
- make_utility(lpc_export lpcx_main.c ${MATH_LIBRARY})
- make_utility(lpc_import lpci_main.c ${MATH_LIBRARY})
- make_executable(mixer-bin mixer_main.c "${CSOUNDLIB};${MATH_LIBRARY}" mixer)
- make_utility(pvanal pvc_main.c)
- make_utility(pvlook pvl_main.c)
- make_utility(pv_export pvx_main.c)
@ -76,15 +68,10 @@ Index: csound-6.12.2/util/CMakeLists.txt
+ SDIF/sdif.c)
+
+if(MSVC)
+ make_plugin(stdutil "${stdutil_SRCS}" )
+ target_link_libraries(stdutil ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
+elseif(WIN32)
+ make_plugin(stdutil "${stdutil_SRCS}" m
+ ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
+else()
+ make_plugin(stdutil "${stdutil_SRCS}" m ${LIBSNDFILE_LIBRARY})
+ set(LIBSNDFILE_LIBRARY sndfile-static)
+endif()
+
+make_plugin(stdutil "${stdutil_SRCS}" ${MATH_LIBRARY} ${LIBSNDFILE_LIBRARY} ${LIBSNDFILE_SUPPORT_LIBS})
+add_dependency_to_framework(stdutil ${LIBSNDFILE_LIBRARY})
+
+if(BUILD_UTILITIES)
@ -98,12 +85,9 @@ Index: csound-6.12.2/util/CMakeLists.txt
+ make_utility(het_import heti_main.c)
+ make_utility(hetro het_main.c)
+ make_utility(lpanal lpc_main.c)
+ make_utility(lpc_export lpcx_main.c)
+ make_utility(lpc_import lpci_main.c)
+ make_executable(mixer-bin mixer_main.c "${CSOUNDLIB}" mixer)
+ if(LINUX)
+ target_link_libraries(mixer-bin m)
+ endif()
+ make_utility(lpc_export lpcx_main.c ${MATH_LIBRARY})
+ make_utility(lpc_import lpci_main.c ${MATH_LIBRARY})
+ make_executable(mixer-bin mixer_main.c "${CSOUNDLIB};${MATH_LIBRARY}" mixer)
+ make_utility(pvanal pvc_main.c)
+ make_utility(pvlook pvl_main.c)
+ make_utility(pv_export pvx_main.c)

View File

@ -1,3 +1,23 @@
-------------------------------------------------------------------
Fri Jul 10 08:45:28 UTC 2020 - Dave Plater <davejplater@gmail.com>
- Removed unused util/new_srconv.c from sources to fix licensing.
-------------------------------------------------------------------
Wed Jun 03 08:03:33 UTC 2020 - davejplater@gmail.com
- Update to version 6.14.0+git20200601 and fix factory build
- Use service file instead of pre_checkin.sh to create tarball.
- Remove incorporated patche fluidsynth2.patch.
* init
* resonbnk and apoleparams
* fix to multicore + etter code
* resonator bank
* fix prepiano meory issue
* allpoleb opcode
* Nearly there
* coeffs to params fix
-------------------------------------------------------------------
Wed Jun 26 08:00:12 UTC 2019 - Dave Plater <davejplater@gmail.com>

View File

@ -1,7 +1,7 @@
#
# spec file for package csound
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -16,12 +16,14 @@
#
%define rev 0dad8304c78efba48b4f405f4757f3e0a7e339c0
%define py3version %(pkg-config python3 --modversion)
%define support_fltk 1
%bcond_with python
%if 0%{?suse_version} > 1500
%bcond_without java
%bcond_with java
%else
%bcond_with java
%endif
@ -30,25 +32,21 @@
%define min 0
Name: csound
Version: 6.12.2
Version: 6.14.0+git20200601
Release: 0
Summary: Computer Sound Synthesis and Composition Program
License: GPL-2.0-or-later AND BSD-3-Clause AND PostgreSQL
License: LGPL-2.1-or-later AND GPL-2.0-or-later
Group: Productivity/Multimedia/Sound/Utilities
Url: http://www.csounds.com
URL: http://www.csounds.com
#Source: https://github.com/%%{name}/%%{name}/archive/%%{version}.tar.gz#/%%{name}-%%{version}.tar.gz
Source0: %{name}-%{version}-distibutable.tar.xz
Source0: %{name}-%{version}.tar.xz
Source1: README.SUSE
Source2: COPYING_gpl2+.txt
#Update and remove undistributable files from the sources and repack with this script
#Usage = sh pre_checkin.sh
Source3: pre_checkin.sh
# Default to using pulseaudio instead of portaudio
Patch2: csound-6.08-default-pulse.patch
# Use xdg-open to open a browser to view the manual
Patch4: csound-6.08-xdg-open.patch
Patch6: fluidsynth2.patch
Patch7: csound-rename-sndinfo.patch
Patch5: csound-rename-sndinfo.patch
BuildRequires: alsa-devel
BuildRequires: bison
BuildRequires: cmake
@ -173,6 +171,7 @@ make %{_smp_mflags}
%cmake_install
#python bindings are wip
rm -rf %{buildroot}root
cp -v OOps/README.md README.OOps
%fdupes -s %{buildroot}
%find_lang %{name}%{maj}
@ -187,8 +186,8 @@ rm -rf %{buildroot}root
%postun java-bindings -p /sbin/ldconfig
%files
%doc AUTHORS README.md README.SUSE Release_Notes
%license COPYING OOps/LICENCE.random COPYING_gpl2+.txt COPYING.PostgreSQL
%doc AUTHORS README.md README.SUSE Release_Notes README.OOps
%license COPYING COPYING_gpl2+.txt COPYING.PostgreSQL
%{_bindir}/*
%files -n libcsnd6-%{maj}_%{min}

View File

@ -1,60 +0,0 @@
Index: csound-6.12.2/Opcodes/fluidOpcodes/fluidOpcodes.cpp
===================================================================
--- csound-6.12.2.orig/Opcodes/fluidOpcodes/fluidOpcodes.cpp 2018-11-07 16:05:23.000000000 +0200
+++ csound-6.12.2/Opcodes/fluidOpcodes/fluidOpcodes.cpp 2019-04-05 15:33:21.652528196 +0200
@@ -208,6 +208,7 @@ public:
} else if (listPresets) {
fluid_sfont_t *fluidSoundfont =
fluid_synth_get_sfont_by_id(fluidSynth, soundFontId);
+#if FLUIDSYNTH_VERSION_MAJOR < 2
fluid_preset_t fluidPreset;
fluidSoundfont->iteration_start(fluidSoundfont);
OPARMS oparms;
@@ -218,6 +219,19 @@ public:
soundFontId, fluidPreset.get_banknum(&fluidPreset),
fluidPreset.get_num(&fluidPreset),
fluidPreset.get_name(&fluidPreset));
+#else
+ fluid_preset_t *fluidPreset;
+ fluid_sfont_iteration_start(fluidSoundfont);
+ OPARMS oparms;
+ csound->GetOParms(csound, &oparms);
+ if (oparms.msglevel & 0x7)
+ while (fluidPreset = fluid_sfont_iteration_next(fluidSoundfont))
+ {
+ log(csound, "SoundFont: %3d Bank: %3d Preset: %3d %s\n",
+ soundFontId, fluid_preset_get_banknum(fluidPreset),
+ fluid_preset_get_num(fluidPreset),
+ fluid_preset_get_name(fluidPreset));
+#endif
}
}
return result;
@@ -279,6 +293,7 @@ public:
toa(iFluidSynth, fluidSynth);
fluid_sfont_t *fluidSoundfont =
fluid_synth_get_sfont(fluidSynth, 0);
+#if FLUIDSYNTH_VERSION_MAJOR < 2
fluid_preset_t fluidPreset;
fluidSoundfont->iteration_start(fluidSoundfont);
OPARMS oparms;
@@ -290,6 +305,19 @@ public:
ss << "Bank: " << fluidPreset.get_banknum(&fluidPreset) <<
" Preset: " << fluidPreset.get_num(&fluidPreset) <<
" Name: " << fluidPreset.get_name(&fluidPreset);
+#else
+ fluid_preset_t *fluidPreset;
+ fluid_sfont_iteration_start(fluidSoundfont);
+ OPARMS oparms;
+ csound->GetOParms(csound, &oparms);
+ if (oparms.msglevel & 0x7)
+ while (fluidPreset = fluid_sfont_iteration_next(fluidSoundfont))
+ {
+ std::stringstream ss;
+ ss << "Bank: " << fluid_preset_get_banknum(fluidPreset) <<
+ " Preset: " << fluid_preset_get_num(fluidPreset) <<
+ " Name: " << fluid_preset_get_name(fluidPreset);
+#endif
programs.push_back(ss.str());
}

View File

@ -1,22 +0,0 @@
#! /bin/bash
vers=$(cat csound.spec|grep "Version: "|cut -b 17-23)
rm -f *.tar.*
wget https://github.com/csound/csound/archive/${vers}.tar.gz || exit 1
echo "\n\nUnpacking tarball\n"
tar -xf ${vers}.tar.gz
echo "Removing undistibutable files\n"
rm -f csound-${vers}/Opcodes/scansyn*
echo "Creating distributable tarball\n"
tar -acf csound-${vers}-distibutable.tar.xz csound-${vers}
echo "Cleaning up\n"
rm -rf csound-${vers} ${vers}.tar.gz
if ! test -e ${vers}.tar.gz;
then
echo "success"
osc ar
exit 0
else
echo "error"
exit 1
fi