File libechonest-qt5.spec of Package libechonest-qt5
#
# spec file for package libechonest-qt5
#
# Copyright (c) 2015 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/
#
%define _major_version 2
%define _minor_version 3
%define _patch_version 0
%define soname %{_major_version}_%{_minor_version}
Name: libechonest-qt5
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkgconfig(Qt5Core)
BuildRequires: pkgconfig(Qt5Network)
BuildRequires: pkgconfig(Qt5Xml)
Version: %{_major_version}.%{_minor_version}.%{_patch_version}+20150206
Release: 0
Source: libechonest-%{version}.tar.bz2
Source1: baselibs.conf
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Url: https://projects.kde.org/libechonest
# main package
Summary: Qt library for communicating with The Echo Nest
License: GPL-2.0+
Group: System/Libraries
%description
It currently supports almost all of the features of the Echo Nest API, including all the API functions.
# bin package
%package -n libechonest5-%{soname}
Summary: Qt library for communicating with The Echo Nest
Group: System/Libraries
%description -n libechonest5-%{soname}
It currently supports almost all of the features of the Echo Nest API, including all the API functions.
# devel package
%package devel
Summary: Qt library for communicating with The Echo Nest
Group: Development/Libraries/C and C++
Requires: libechonest5-%{soname} = %{version}
%description devel
It currently supports almost all of the features of the Echo Nest API, including all the API functions.
%prep
%setup -q -n libechonest-%{version}
%build
export CXXFLAGS="%{optflags}"
export CFLAGS="%{optflags}"
cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DECHONEST_BUILD_TESTS=OFF \
-DBUILD_WITH_QT4=OFF \
%if "%{_lib}" == "lib64"
-DLIB_SUFFIX=64
%endif
make VERBOSE=1 %{?_smp_mflags}
%install
make DESTDIR=%{buildroot} install
%post -n libechonest5-%{soname} -p /sbin/ldconfig
%postun -n libechonest5-%{soname} -p /sbin/ldconfig
%files -n libechonest5-%{soname}
%defattr(-,root,root,-)
%doc COPYING*
%{_libdir}/libechonest*.so.*
%files devel
%defattr(-,root,root,-)
%doc COPYING*
%{_libdir}/libechonest*.so
%{_includedir}/echonest5/
%{_libdir}/pkgconfig/libechonest5.pc
%changelog