File linuxsampler.spec of Package linuxsampler

# vim: set sw=4 ts=4 et:

# Copyright (c) 2005-2010 oc2pus
# Copyright (c) 2012 Pascal Bleser <pascal.bleser@opensuse.org>
#
# 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 to packman@links2linux.de

%define soname	3

Name:           linuxsampler
Summary:        LinuxSampler - modular, streaming capable sampler
%define rev     2680
Version:        1.0.0+r%{rev}
Release:        6.15
License:        GPL-2.0+
Group:          Productivity/Multimedia/Sound/Utilities
URL:            http://www.linuxsampler.org/
## http://download.linuxsampler.org/packages/linuxsampler-%{version}.tar.bz2
Source0:        linuxsampler-%{rev}.tar.bz2
Source1:        linuxsampler.png

BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  alsa-devel >= 1.0.9
BuildRequires:  libtool autoconf automake >= 1.5
BuildRequires:  gcc-c++
BuildRequires:  bison
BuildRequires:  dssi-devel
BuildRequires:  ladspa-devel
BuildRequires:  libgig-devel
BuildRequires:  libjack-devel >= 0.103
# It should be pkgconfig(lv2). But leave it like this for compatibility.
# openSUSE 12.3 was the first version using lv2 instead of lv2core.
BuildRequires:  pkgconfig(lv2core)
BuildRequires:  pkgconfig
BuildRequires:  sqlite3-devel
BuildRequires:  libsndfile-devel >= 1.0.0
BuildRequires:  doxygen
BuildRequires:  flex
BuildRequires:  perl-XML-Parser
BuildRequires:  update-desktop-files
Requires:       alsa >= 1.0.9
Requires:       jack >= 0.103

%description
LinuxSampler is a work in progress. The goal is to produce a free,
open source pure software audio sampler with professional grade
features, comparable to both hardware and commercial Windows/Mac
software samplers and to introduce new features not yet available
by any other sampler in the world.

LinuxSampler was designed as a sampler backend, decoupled from any
user interface. It provides a network interface using an ASCII based
protocol called LSCP for full control of the sampler like for setup
and altering sampler sessions. But don't be afraid, with QSampler we
already have a convenient GUI frontend (based on the cross-platform
GUI library Qt) for LinuxSampler and due to the decoupled design you
can even control the sampler with the GUI frontend from another
computer, probably even running another OS like Windows or OSX.
Beside our own custom network control layer we planned to add
existing ones as well (e.g. OSC). With the planned SMP and cluster
support LinuxSampler might become a standard for high-end studios
and concerts.

It is planned to support all common sampler formats in LinuxSampler,
but at the moment we chose to concentrate on the Gigasampler format,
because we think it's currently the best sampler format in regards
of quality and power, especially for the synthesis of natural
instruments like pianos, brass and bowed instruments.
But we already made good advance in implementing this format, so we
are optimistic to start with adding other formats soon. Beside that
we also planned to design our own, sophisticated sampler format to
introduce a more powerful and more flexible sampler format compared
to any sampler format currently available in the world. Be encouraged
to share your ideas about such a new format with us!

%package -n liblinuxsampler%{soname}
Summary:        Shared libraries for linuxsampler
Group:          System/Libraries
Provides:       liblinuxsampler1 = 0.5.1
Obsoletes:      liblinuxsampler1 < 0.5.1

%description -n liblinuxsampler%{soname}
This package contains the shared libraries for linuxsampler.

%package -n liblinuxsampler-devel
Summary:        Development files for linuxsampler
Group:          Development/Languages/C and C++
Requires:       liblinuxsampler%{soname} = %{version}
Requires:       dssi-devel
Requires:       ladspa-devel

%description -n liblinuxsampler-devel
This package contains header files, libraries and documentation for
writing and compiling programs using linuxsampler.

%package doc
Summary:        Documentation for linuxampler
Group:          Documentation/HTML

%description doc
This package contains the documentation for linuxampler.

%package -n dssi-linuxsampler
Summary:        DSSI plugin
Group:          System/Libraries
Requires:       dssi

%description -n dssi-linuxsampler
This package contains the dssi-plugin for package linuxsampler.

%package -n lv2-linuxsampler
Summary:        LV2 plugin
Group:          System/Libraries

%description -n lv2-linuxsampler
This package contains the lv2-plugin for package linuxsampler.

%prep
%setup -q -n linuxsampler

%build
[ -e ./configure ] || %__make -f Makefile.cvs configure

%configure \
    --disable-static \
    --enable-optimize \
    --disable-arts-driver \
    --enable-plugin-dir="%{_prefix}/lib/%{name}/plugins" \
    --enable-default-instruments-db-location="%{_var}/lib/%{name}/instruments.db"

%__make %{?_smp_flags}

%install
%makeinstall

# icon and menu-entry
%__install -dm 755 %{buildroot}%{_datadir}/pixmaps
%__install -m 644 %{SOURCE1} \
    %{buildroot}%{_datadir}/pixmaps

%__cat > %{name}.desktop << EOF
[Desktop Entry]
Comment=LinuxSampler - modular, streaming capable sampler
Comment[de]=LinuxSampler - modularer, streaming faehiger sampler
Exec=%{name}
GenericName=%{name}
GenericName[de]=%{name}
Icon=%{name}
Name=LinuxSampler
Name[de]=LinuxSampler
StartupNotify=true
Terminal=false
Type=Application
X-DCOP-ServiceType=
X-KDE-SubstituteUID=false
Encoding=UTF-8
Categories=AudioVideo;Sequencer;
EOF
%suse_update_desktop_file -n -i %{name} AudioVideo Sequencer

touch src/engines/InstrumentEditor.h
touch src/engines/InstrumentEditorFactory.h
%__make docs

%__rm %{buildroot}%{_libdir}/%{name}/*.la
%__rm %{buildroot}%{_libdir}/dssi/*.la
%__rm %{buildroot}%{_libdir}/lv2/%{name}.lv2/%{name}.la
%__rm Documentation/Engines/gig/Makefile*

%__install -d "%{buildroot}%{_usr}/lib/%{name}/plugins"

mkdir -p %{buildroot}%{_sysconfdir}/ld.so.conf.d/
  echo "%{_libdir}/%{name}" > "%{buildroot}%{_sysconfdir}/ld.so.conf.d/liblinuxsampler%{soname}.conf"

%post   -n %{name} -p /sbin/ldconfig
%postun -n %{name} -p /sbin/ldconfig  
  
%clean
%{?buildroot:%__rm -rf "%{buildroot}"}

%post   -n liblinuxsampler%{soname} -p /sbin/ldconfig
%postun -n liblinuxsampler%{soname} -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog NEWS README
%{_bindir}/%{name}
%{_bindir}/ls_instr_script
%{_bindir}/lscp
%{_mandir}/man1/*
%{_datadir}/pixmaps/%{name}.png
%{_datadir}/applications/%{name}.desktop
%dir %{_usr}/lib/%{name}
%dir %{_usr}/lib/%{name}/plugins
%dir %{_var}/lib/%{name}
%{_var}/lib/%{name}/instruments.db

%files -n liblinuxsampler%{soname}
%defattr(-,root,root)
%dir %{_libdir}/%{name}
%{_libdir}/%{name}/*.so.%{soname}
%{_libdir}/%{name}/*.so.%{soname}.*
%config %{_sysconfdir}/ld.so.conf.d/liblinuxsampler%{soname}.conf

%files -n liblinuxsampler-devel
%defattr(-,root,root)
%{_includedir}/*
%dir %{_libdir}/%{name}
%{_libdir}/%{name}/*.so
%{_libdir}/pkgconfig/%{name}.pc

%files doc
%defattr(-,root,root)
%doc Documentation/*

%files -n dssi-linuxsampler
%defattr(-,root,root)
%dir %{_libdir}/dssi
%{_libdir}/dssi/%{name}.so

%files -n lv2-linuxsampler
%defattr(-,root,root)
%dir %{_libdir}/lv2
%dir %{_libdir}/lv2/%{name}.lv2
%{_libdir}/lv2/%{name}.lv2/%{name}.so
%{_libdir}/lv2/%{name}.lv2/*.ttl

%changelog
* Wed Dec 17 2014 giordanoboschetti@gmail.com
- update to svn trunk rev 2680
* Mon Oct 20 2014 avvissu@yandex.ru
- Patch to fix build on ARM processors (add linuxsampler_arm.patch)
* Tue Aug 13 2013 reddwarf@opensuse.org
- Change lv2core-devel BuildRequire for pkgconfig(lv2core)
* Mon Apr 16 2012 pascal.bleser@opensuse.org
- update to svn rev 2342
* Sat Feb 27 2010 toni@links2linux.de
- update to 1.0.0
- added lv2- and dssi-plugin sub-package
- so-name changed ==> liblinuxsampler3
* Fri Dec  7 2007 toni@links2linux.de
- update to 0.5.1
* Mon Oct 15 2007 toni@links2linux.de
- update to 0.5.0-cvs20071015
- so-name changed ==> liblinuxsampler1
* Sun Oct 14 2007 toni@links2linux.de
- update to 0.4.0.8-cvs20071014
* Sun Oct  7 2007 toni@links2linux.de
- update to 0.4.0.7-cvs20071004
* Tue Oct  2 2007 toni@links2linux.de
- update to 0.4.0.7-cvs20071001
* Tue Sep 11 2007 toni@links2linux.de
- update to 0.4.0.7-cvs20070910
* Fri Jul  6 2007 toni@links2linux.de
- update to 0.4.0.6-cvs20070625
* Sun Jun  3 2007 toni@links2linux.de
- update to 0.4.0.5-cvs20070601
- changed package-layout according new Shared Library Packaging Policy
* Sat May 26 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070525
* Sun May 13 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070513
* Fri May  4 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070504
* Mon Apr 16 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070416
* Mon Apr  9 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070408
* Sat Mar 24 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070324
* Wed Feb 28 2007 toni@links2linux.de
- update to 0.4.0.4-cvs20070228
* Sat Feb 10 2007 toni@links2linux.de
- update to 0.4.0.3-cvs20070210
* Mon Feb  5 2007 toni@links2linux.de
- update to 0.4.0.2-cvs20070204
* Wed Jan 24 2007 toni@links2linux.de
- update to 0.4.0.2-cvs20070123
* Tue Jan 16 2007 toni@links2linux.de
- update to 0.4.0.2-cvs20070116
* Thu Jan 11 2007 toni@links2linux.de
- update to 0.4.0.2-cvs20070111
* Sun Dec 31 2006 toni@links2linux.de
- update to 0.4.0.1-cvs20061230
* Fri Dec 22 2006 toni@links2linux.de
- update to 0.4.0.1-cvs20061222
* Mon Dec 18 2006 toni@links2linux.de
- update to 0.4.0.1-cvs20061218
* Wed Nov 29 2006 toni@links2linux.de
- update to 0.4.0 final
* Mon Nov 27 2006 toni@links2linux.de
- 0.4.0-cvs 20061127
* Sun Nov  5 2006 toni@links2linux.de
- cvs 20061105
* Sun Oct 22 2006 toni@links2linux.de
- cvs 20061022
* Tue Oct  3 2006 toni@links2linux.de
- cvs 20061003
* Mon Sep 18 2006 toni@links2linux.de
- build for packman
* Sat Aug  5 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060805
- cvs 20060805
* Sat Jul 29 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060729
- cvs 20060729
* Sun Jul 23 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060723
- cvs 20060723
* Wed Jul  5 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060705
- cvs 20060705
* Sat Jul  1 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060701
- cvs 20060701
* Wed Jun 28 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060628
- cvs 20060628
* Sun Jun 25 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060625
- cvs 20060625
* Thu Jun  1 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060601
- cvs 20060601
* Thu May 25 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060525
- cvs 20060525
* Sun May 14 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060514
- cvs 20060514
* Tue Apr 11 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060411
- cvs 20060411
* Sat Mar 25 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060325
- cvs 20060325
- changed KDE menu entry
* Sat Mar  4 2006 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20060304
- cvs 20060304
* Mon Dec 26 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051226
- cvs 20051226
* Thu Dec 22 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051222
- cvs 20051222
* Fri Nov 25 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051125
- cvs 20051125
* Tue Nov 22 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051122
- cvs 20051122
* Thu Nov 17 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051117
- cvs 20051117
* Sat Nov 12 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051112
- cvs 20051112
* Fri Nov  4 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051104
- cvs 20051104
* Sat Oct 29 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051029
- cvs 20051029
* Sun Oct  2 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20051002
- cvs 20051002
* Mon Sep 26 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050926
- cvs 20050926
- split in two packages (-devel)
* Thu Sep 22 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050922
- cvs 20050922
* Sun Sep 11 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050911
- cvs 20050911
* Wed Sep  7 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050907
- cvs 20050907
* Wed Aug 17 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050816
- cvs 20050816
* Tue Aug  2 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050730
- cvs 20050730
* Mon Jul 25 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050724
- cvs 20050724
- added API-doc
* Mon Jul 18 2005 oc2pus@arcor.de 0.3.3-0.oc2pus.cvs20050718
- cvs 20050718
* Wed Jul 13 2005 oc2pus@arcor.de 0.3.2-0.oc2pus.cvs20050713
- cvs 20050713
* Wed Jul  6 2005 oc2pus@arcor.de 0.3.2-0.oc2pus.cvs20050706
- cvs 20050706
* Wed Jun 29 2005 oc2pus@arcor.de 0.3.2-0.oc2pus.cvs20050629
- cvs 20050629
* Sun Jun 19 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050619
- cvs 20050619
* Thu Jun 16 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050616
- cvs 20050616
* Mon Jun 13 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050613
- cvs 20050613
* Fri Jun 10 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050610
- cvs 20050610
* Tue Jun  7 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050607
- cvs 20050607
* Mon Jun  6 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050606
- cvs 20050606
* Wed Jun  1 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050601
- cvs 20050601
* Mon May 23 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050523
- cvs 200500523
* Sat May 21 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050521
- cvs 200500521
* Thu May 19 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050519
- cvs 200500519
* Wed May 18 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050518
- cvs 200500518
* Mon May  9 2005 oc2pus@arcor.de 0.3.1-0.oc2pus.cvs20050509
- cvs 200500509
* Sun May  8 2005 oc2pus@arcor.de 0.3.0-0.oc2pus.cvs20050508
- cvs 200500508
* Thu May  5 2005 oc2pus@arcor.de 0.3.0-0.oc2pus.cvs20050505
- cvs 200500505
* Tue May  3 2005 oc2pus@arcor.de 0.3.0-0.oc2pus.cvs20050505
- cvs 200500503
- added libgig(-devel) to BuildRequires/Requires
* Sat Apr 30 2005 oc2pus@arcor.de 0.3.0-0.oc2pus.cvs20050429
- cvs 20050429
* Fri Apr  8 2005 oc2pus@arcor.de 0.2.0-0.oc2pus.cvs20050408
- cvs 20050408
- changed icon to original linuxsampler icon
- removed external desktop-file
* Sun Mar 27 2005 oc2pus@arcor.de 0.2.0-0.oc2pus.cvs20050327
- cvs 20050327
* Sun Mar 20 2005 oc2pus@arcor.de 0.2.0-0.oc2pus.cvs20050320
- cvs 20050320
- changed name of rpm, changed to tar.bz2
* Mon Mar  7 2005 oc2pus@arcor.de 0.2.0-0.oc2pus.1
- initial release of rpm
- cvs 20050225