File supercollider-sc3-plugins.spec of Package supercollider-sc3-plugins

#
# spec file for package supercollider-sc3-plugins
#
# Copyright (c) 2014 SUSE LINUX Products 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/
#

# how to prepare the source...
#
# git clone git://github.com/supercollider/sc3-plugins.git
# cd sc3-plugins
# git submodule init
# git submodule update
# git describe
# cd ..
# mv sc3-plugins sc3-plugins-src-gXXXXXXX
# tar cvzf sc3-plugins-src-gXXXXXXX.tar.gz sc3-plugins-src-gXXXXXXX
#
# 2015.08.02: 3.5-260-g9367339
#

%define build_supernova 1

# what extra options to compile with
%define cmakearch -DSSE=OFF
%ifarch x86_64
%define cmakearch -DSSE=ON -DX86_64=ON
%endif
%ifarch %ix86
%define cmakearch -DSSE=ON -DI686=ON
%endif
# options to build supernova
%if 0%{?build_supernova}
%define cmakesupernova -DSUPERNOVA=ON
%else
%define cmakesupernova -DSUPERNOVA=OFF
%endif

Name:           supercollider-sc3-plugins
Version:        3.11.1+git.48.4416f95
Release:        0
Summary:        Collection of SuperCollider plugins
License:        GPL-3.0
Group:          Applications/Multimedia
Url:            http://sc3-plugins.sourceforge.net/
Source0:        %{name}-%{version}.tar.gz
Source99:       supercollider-sc3-plugins-rpmlintrc
BuildRequires:  cmake
BuildRequires:  fdupes
BuildRequires:  gcc-c++
BuildRequires:  fftw-devel
BuildRequires:  supercollider-devel
Requires:       supercollider >= 3.5
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
Collection of free and usefull SuperCollider plugins

%prep
%setup -q

%build
%ifarch ppc ppc64 ppc64le
export CFLAGS='%{optflags} -mno-altivec'
export CXXFLAGS='%{optflags} -mno-altivec'
%endif
%cmake \
	-DSC_PATH=%{_includedir}/SuperCollider \
	%{cmakearch} \
	-DQUARKS=ON \
	%{?cmakesupernova}
make clean %{?_smp_mflags}
make %{?_smp_mflags}

%install
cd build
make DESTDIR=%{buildroot} install %{?_smp_mflags}
%fdupes %{buildroot}%{_prefix}

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%dir %{_datadir}/SuperCollider
%dir %{_datadir}/SuperCollider/SC3plugins
%{_datadir}/SuperCollider/SC3plugins
%dir %{_libdir}/SuperCollider
%dir %{_libdir}/SuperCollider/plugins
%{_libdir}/SuperCollider/plugins

%changelog
openSUSE Build Service is sponsored by