]> git.pld-linux.org Git - packages/clementine.git/blame_incremental - clementine.spec
- libcdio related rebuild
[packages/clementine.git] / clementine.spec
... / ...
CommitLineData
1# TODO:
2# - Gstreamer error: "A text/uri-list decoder plugin is required to play this stream, but not installed."
3# - apply patches to libprojectM.spec and use
4# - package for kde4 stuff (or nuke them):
5# /usr/share/kde4/services/clementine-feed.protocol
6# /usr/share/kde4/services/clementine-itms.protocol
7# /usr/share/kde4/services/clementine-itpc.protocol
8# /usr/share/kde4/services/clementine-zune.protocol
9#
10# Conditional build:
11%bcond_without static_sqlite # with static sqlite3
12%bcond_with static_projectm # with static projectM
13%bcond_with libspotify # build with system libspotify instead of downloading blob
14%bcond_without tests # build without tests
15
16%define qtver %(pkg-config --silence-errors --modversion QtCore 2>/dev/null || echo ERROR)
17Summary: A music player and library organiser
18Summary(hu.UTF-8): Egy zenelejátszó és gyűjtemény-kezelő
19Name: clementine
20Version: 1.2.1
21Release: 2
22License: GPL v3 and GPL v2+
23Group: Applications/Multimedia
24Source0: http://clementine-player.googlecode.com/files/%{name}-%{version}.tar.gz
25# Source0-md5: 5d079e12f5925845cc7e38ce2f4a1e20
26Patch0: desktop-install.patch
27Patch1: unbundle-po.patch
28Patch3: %{name}-dt_categories.patch
29Patch4: %{name}-mygpo.patch
30Patch5: %{name}-desktop.patch
31URL: http://www.clementine-player.org/
32BuildRequires: QtCore-devel >= %{qtver}
33BuildRequires: QtDBus-devel >= %{qtver}
34BuildRequires: QtGui-devel >= %{qtver}
35BuildRequires: QtIOCompressor-devel
36BuildRequires: QtNetwork-devel >= %{qtver}
37BuildRequires: QtOpenGL-devel >= %{qtver}
38BuildRequires: QtSingleApplication-devel >= 2.6-4
39BuildRequires: QtSql-devel >= %{qtver}
40%{?with_tests:BuildRequires: QtTest-devel >= %{qtver}}
41BuildRequires: QtXml-devel >= %{qtver}
42BuildRequires: QtXmlPatterns-devel >= %{qtver}
43BuildRequires: boost-devel
44BuildRequires: cmake >= 2.6
45BuildRequires: desktop-file-utils
46BuildRequires: gettext-devel
47%{?with_static_projectm:BuildRequires: glew-devel}
48BuildRequires: glib2-devel
49BuildRequires: gstreamer0.10-devel
50BuildRequires: gstreamer0.10-plugins-base-devel
51BuildRequires: gtest-devel
52BuildRequires: libcdio-devel
53BuildRequires: libchromaprint-devel
54BuildRequires: libechonest-devel
55BuildRequires: libgpod-devel >= 0.7.92
56BuildRequires: libimobiledevice-devel >= 1.1.5
57BuildRequires: libindicate-qt-devel
58BuildRequires: liblastfm-devel >= 0.3.3
59BuildRequires: libmtp-devel
60BuildRequires: libmygpo-qt-devel >= 1.0.7
61BuildRequires: libplist-devel
62%{!?with_static_projectm:BuildRequires: libprojectM-devel >= 1:2.0.1-4}
63BuildRequires: libqxt-devel
64%{?with_libspotify:BuildRequires: libspotify-devel >= 12.1.45}
65BuildRequires: libxml2-devel
66BuildRequires: pkgconfig
67BuildRequires: pkgconfig
68BuildRequires: protobuf-devel
69BuildRequires: qca-devel
70BuildRequires: qjson-devel
71BuildRequires: qt4-build >= %{qtver}
72BuildRequires: qt4-linguist
73BuildRequires: qt4-qmake
74BuildRequires: rpmbuild(find_lang) >= 1.33
75BuildRequires: rpmbuild(macros) >= 1.596
76BuildRequires: sed >= 4.0
77BuildRequires: sparsehash-devel
78%{!?with_static_sqlite:BuildRequires: sqlite3-devel}
79BuildRequires: taglib-devel >= 1.6
80BuildRequires: usbmuxd-devel
81Requires(post,postun): desktop-file-utils
82Requires(post,postun): gtk-update-icon-cache
83Requires(post,postun): hicolor-icon-theme
84Requires: QtSingleApplication >= 2.6-4
85%{!?with_static_sqlite:Requires: QtSql-sqlite3 >= %{qtver}}
86Requires: gstreamer0.10-audio-effects-base
87Requires: gstreamer0.10-mad
88Suggests: gstreamer0.10-flac
89# if we do not link, we use datafiles
90%{!?with_static_projectm:Requires: libprojectM}
91BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
92
93# see libprojectM.spec for explanation
94%define filterout_ld -Wl,--as-needed -Wl,--no-copy-dt-needed-entries
95
96%description
97Clementine is a modern music player and library organiser. It is
98largely a port of Amarok 1.4, with some features rewritten to take
99advantage of Qt4.
100
101%description -l hu.UTF-8
102Clementine egy modern zenelejátszó és gyűjtemény kezelő. Túlnyomórészt
103az Amarok 1.4 port-ja, néhány funkciója újraírva, hogy kihasználhassa
104a Qt4 előnyeit.
105
106%prep
107%setup -q
108%patch0 -p1
109%patch1 -p1
110%patch3 -p1
111%patch4 -p1
112%patch5 -p1
113
114# Remove all 3rdparty libraries except:
115# - universalchardet - not available as a separate library.
116# - libprojectM - see bcond
117# - sha2 - ?
118# - qocoa - ?
119# - qsqlite - see bcond
120mv 3rdparty 3rdparty.keep
121install -d 3rdparty
122mv 3rdparty.keep/{sha2,qocoa%{?with_static_sqlite:,qsqlite}%{?with_static_projectm:,libprojectm}} 3rdparty
123
124# Don't build tests. They require gmock
125sed -i -e '/add_subdirectory(tests)/d' CMakeLists.txt
126# remove -Wall
127sed -i -e 's/-Wall//' src/CMakeLists.txt
128# ...and -Werror
129sed -i -e 's/-Werror//' src/CMakeLists.txt
130
131%build
132install -d build
133install -d build/src/translations
134cd build
135# as our buildtype is not Release, need to pass these manually. see CMakeLists.txt ~125
136CXXFLAGS="%{rpmcxxflags} -DNDEBUG -DQT_NO_DEBUG_OUTPUT"
137%cmake \
138 -DBUNDLE_PROJECTM_PRESETS=OFF \
139 -DUSE_SYSTEM_QTSINGLEAPPLICATION=ON \
140 -DQTSINGLEAPPLICATION_INCLUDE_DIRS=%{_includedir}/qt4/QtSolutions/ \
141 -DUSE_SYSTEM_QXT=ON \
142 -DUSE_SYSTEM_PROJECTM=ON \
143 -DSTATIC_SQLITE=%{?with_static_sqlite:ON}%{!?with_static_sqlite:OFF} \
144 ..
145%{__make}
146
147%if %{with tests}
148desktop-file-validate ../dist/%{name}.desktop
149%endif
150
151%install
152rm -rf $RPM_BUILD_ROOT
153%{__make} -C build install \
154 DESTDIR=$RPM_BUILD_ROOT
155
156rm $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/scalable/apps/application-x-clementine.svg
157
158# not in our glibc?
159rm -r $RPM_BUILD_ROOT%{_localedir}/tr_TR
160rm -r $RPM_BUILD_ROOT%{_localedir}/he_IL
161rm -r $RPM_BUILD_ROOT%{_localedir}/mk_MK
162rm -r $RPM_BUILD_ROOT%{_localedir}/si_LK
163
164%find_lang %{name} --with-qm
165
166install -d $RPM_BUILD_ROOT%{_iconsdir}/hicolor/24x24/apps
167cp -p dist/icons/ubuntu-mono-light/clementine-panel-grey.png $RPM_BUILD_ROOT%{_iconsdir}/hicolor/24x24/apps/clementine-panel-grey.png
168cp -p dist/icons/ubuntu-mono-light/clementine-panel.png $RPM_BUILD_ROOT%{_iconsdir}/hicolor/24x24/apps/clementine-panel.png
169
170%clean
171rm -rf $RPM_BUILD_ROOT
172
173%post
174%update_desktop_database_post
175%update_icon_cache hicolor
176
177%postun
178%update_desktop_database_postun
179%update_icon_cache hicolor
180
181%files -f %{name}.lang
182%defattr(644,root,root,755)
183%doc Changelog
184%attr(755,root,root) %{_bindir}/clementine
185%attr(755,root,root) %{_bindir}/clementine-tagreader
186%{_desktopdir}/clementine.desktop
187%{_pixmapsdir}/clementine.png
188%{_iconsdir}/hicolor/*/apps/clementine-panel-grey.png
189%{_iconsdir}/hicolor/*/apps/clementine-panel.png
This page took 0.053794 seconds and 4 git commands to generate.