File zyn-fusion.spec of Package zyn-fusion
# spec file for package zyn-fusion
#
# Copyright (c) 2019 Fabio Pesari
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
#
# Please submit bugfixes or comments via http://bugs.opensuse.org/
%define zynver 3.0.6
%define zestver 3.0.6+git66.83387df
Name: zyn-fusion
Version: %{zynver}+zest.%{zestver}
Release: 0
Summary: A Real-Time Software Synthesizer for Linux
License: GPL-2.0-or-later and LGPL-2.1
Group: Productivity/Multimedia/Sound/Midi
Url: http://zynaddsubfx.sourceforge.net/zyn-fusion.html
Source0: https://sourceforge.net/projects/zynaddsubfx/files/zynaddsubfx/%{zynver}/zynaddsubfx-%{zynver}.tar.bz2/download#/zynaddsubfx-%{zynver}.tar.bz2
Source1: mruby-zest-build-%{zestver}.tar.gz
Source2: zyn-fusion-alsa.desktop
Source3: zyn-fusion-jack.desktop
Source4: zyn-fusion.svg
Patch0: zynaddsubfx-buildflags.patch
Patch1: fix-missing-include.patch
BuildRequires: gcc-c++
BuildRequires: cmake
BuildRequires: libjpeg-devel
BuildRequires: libpng-devel
BuildRequires: pkgconfig
BuildRequires: update-desktop-files
BuildRequires: libtool
BuildRequires: automake
BuildRequires: ruby-devel
BuildRequires: python3
BuildRequires: bison
BuildRequires: libX11-devel
BuildRequires: Mesa-libGL-devel
BuildRequires: pkgconfig(alsa)
BuildRequires: pkgconfig(fftw3)
BuildRequires: pkgconfig(fftw3f)
BuildRequires: pkgconfig(fftw3l)
BuildRequires: pkgconfig(jack)
BuildRequires: pkgconfig(liblo)
BuildRequires: pkgconfig(libuv)
BuildRequires: pkgconfig(libpulse)
BuildRequires: pkgconfig(mxml)
BuildRequires: pkgconfig(portaudio-2.0)
BuildRequires: pkgconfig(xpm)
BuildRequires: pkgconfig(zlib)
Conflicts: zynaddsubfx
%description
zyn-fusion is a many-featured real-time software synthesizer for
Linux. Features include polyphony and multitimbrel and microtonal
capabilities. It includes randomness of some parameters, which can make
warm sounds, like analog synthesizers. This program has system and
insertion effects, too.
%package -n lv2-zyn-fusion
Summary: Real-time software synthesizer, LV2 Plugin version
Group: Productivity/Multimedia/Sound/Midi
Requires: zyn-fusion = %{version}
Requires: zynaddsubfx-common = %{zynver}
Conflicts: lv2-zynaddsubfx
%description -n lv2-zyn-fusion
zyn-fusion is a many-featured real-time software synthesizer for
Linux. Features include polyphony and multitimbrel and microtonal
capabilities. It includes randomness of some parameters, which can make
warm sounds, like analog synthesizers. This program has system and
insertion effects, too.
This package includes the LV2 zyn-fusion synthesizer plugins.
%package vst
Summary: Real-time software synthesizer, VST Plugin version
Group: Productivity/Multimedia/Sound/Midi
Requires: zyn-fusion = %{version}
Requires: zynaddsubfx-common = %{zynver}
Conflicts: zynaddsubfx-vst
%description vst
zyn-fusion is a many-featured real-time software synthesizer for
Linux. Features include polyphony and multitimbrel and microtonal
capabilities. It includes randomness of some parameters, which can make
warm sounds, like analog synthesizers. This program has system and
insertion effects, too.
This package includes the VST zyn-fusion synthesizer plugins.
%prep
%setup -q -T -b 0 -b 1 -n zynaddsubfx-%{zynver}
%autopatch -p1
%build
cmake \
-DCMAKE_POLICY_VERSION_MINIMUM=3.11 \
-DDefaultOutput=jack \
-DNoNeonPlease:BOOL=ON \
-DOssEnable:BOOL=FALSE \
-DGuiModule=zest \
-DCMAKE_INSTALL_PREFIX:PATH=/usr \
-DX86Build=ON \
-DPluginLibDir:STRING=lib64
make
cd ../mruby-zest-build-%{zestver}
%make_build
make pack
cd ..
%install
%make_install
mkdir -p %{buildroot}/opt/zyn-fusion/
mkdir -p %{buildroot}/opt/zyn-fusion/qml/
touch %{buildroot}/opt/zyn-fusion/qml/MainWindow.qml
cp -a instruments/examples instruments/banks %{buildroot}/opt/zyn-fusion/
rm -rf %{buildroot}%{_datadir}
cd ../mruby-zest-build-%{zestver}
install -m 755 package/zest %{buildroot}/opt/zyn-fusion/zyn-fusion
cp -ra package/{libzest.so,font,schema} %{buildroot}/opt/zyn-fusion
cd ..
install -D -m 644 %{SOURCE4} %{buildroot}%{_datadir}/pixmaps/zyn-fusion.svg
install -D -m 644 %{SOURCE2} %{buildroot}%{_datadir}/applications/zyn-fusion-alsa.desktop
install -D -m 644 %{SOURCE3} %{buildroot}%{_datadir}/applications/zyn-fusion-jack.desktop
%suse_update_desktop_file -r %{name}-alsa AudioVideo Music
%suse_update_desktop_file -r %{name}-jack AudioVideo Music
ln -rs %{buildroot}/opt/zyn-fusion/zyn-fusion %{buildroot}%{_bindir}/zyn-fusion
%files
%{_bindir}/zyn-fusion
%{_bindir}/zynaddsubfx
/opt/zyn-fusion/
%{_datadir}/applications/%{name}*.desktop
%{_datadir}/pixmaps/%{name}.svg
%files -n lv2-zyn-fusion
%{_libdir}/lv2/
%files vst
%{_libdir}/vst/
%changelog