mirror of
https://abf.rosa.ru/djam/clementine.git
synced 2025-02-23 15:02:55 +00:00
186 lines
6.4 KiB
RPMSpec
186 lines
6.4 KiB
RPMSpec
%define shortcommit gd3b819c3e
|
|
%define gitrelease 33
|
|
|
|
######################
|
|
# Hardcode PLF build
|
|
%bcond_with plf
|
|
######################
|
|
|
|
%if %{with plf}
|
|
# make EVR of plf build higher than regular to allow update, needed with rpm5 mkrel
|
|
%define extrarelsuffix plf
|
|
%endif
|
|
|
|
%define gstapi 1.0
|
|
%define oname Clementine
|
|
|
|
# The last official release was in April 2016, but in the devel tree
|
|
# there are commits as recents as August 2018: let's build a devel snapshot
|
|
# to pick up a boatload of changes and fixes
|
|
%define gitdate 20180812
|
|
|
|
Summary: A cross-platform music player based on Amarok 1.4
|
|
Name: clementine
|
|
Version: 1.4.1
|
|
Release: %{gitrelease}%{?extrarelsuffix}
|
|
License: GPLv3+
|
|
Group: Sound
|
|
URL: http://www.clementine-player.org
|
|
#Source0: https://github.com/clementine-player/Clementine/archive/%%{oname}-%%{version}.tar.gz
|
|
#Source0: %{name}-%{gitdate}.tar.xz
|
|
#Source0: %{oname}-qt5.zip
|
|
Source0: https://github.com/clementine-player/Clementine/archive/%{version}-%{gitrelease}-%{shortcommit}/%{oname}-%{version}-%{gitrelease}-%{shortcommit}.tar.gz
|
|
Source1: %{oname}.conf
|
|
Source100: %{name}.rpmlintrc
|
|
# The sources version is still 1.3.1: fake a new one...
|
|
Patch0: clementine-fake-new-version.patch
|
|
Patch1: clementine-1.3.2-use-system-libmygpo_qt.patch
|
|
# Search albums at metal-archives.com (Encyclopaedia Metallum) from:
|
|
# - Now Playing widget (album art context menu) - current album
|
|
# - Playlist (selected songs context menu) - unique selected albums
|
|
Patch2: clementine-1.3.2-metalarchives.patch
|
|
Patch3: clementine-1.3.2-desktop-initial-pref.patch
|
|
# Localization issues
|
|
Patch4: clementine-1.3.2-fix-l10n-issues.patch
|
|
Patch5: clementine-1.3.2-desktop-add-play-folder.patch
|
|
# RockRadio.com has Premium access for long time already
|
|
# It's especially important to fix after free access to DI.fm services was disabled in
|
|
# https://github.com/clementine-player/Clementine/commit/3ab20defce71a009bf180255642c18fa671650f9
|
|
Patch6: clementine-1.3.2-rockradio-premium.patch
|
|
Patch7: clementine-1.3.1-sqlite-3.12.patch
|
|
# Our gxx does not know a thing about no-unknown-warning-option
|
|
# and no-unused-private-field
|
|
Patch8: clementine-1.3.2-fix-unkwnon-gcc-commands.patch
|
|
Patch9: clementine-fix-version.patch
|
|
BuildRequires: cmake
|
|
BuildRequires: gettext
|
|
BuildRequires: qt5-linguist
|
|
BuildRequires: boost-devel
|
|
BuildRequires: fftw3-devel
|
|
BuildRequires: liblastfm-devel
|
|
#BuildRequires: qt4-devel >= 4.8.1
|
|
BuildRequires: pkgconfig(alsa)
|
|
BuildRequires: pkgconfig(cryptopp)
|
|
BuildRequires: pkgconfig(gl)
|
|
BuildRequires: pkgconfig(glew)
|
|
BuildRequires: pkgconfig(glib-2.0)
|
|
BuildRequires: pkgconfig(glu)
|
|
BuildRequires: pkgconfig(gstreamer-%{gstapi})
|
|
BuildRequires: pkgconfig(gstreamer-app-%{gstapi})
|
|
BuildRequires: pkgconfig(gstreamer-audio-%{gstapi})
|
|
BuildRequires: pkgconfig(gstreamer-base-%{gstapi})
|
|
BuildRequires: pkgconfig(gstreamer-tag-%{gstapi})
|
|
BuildRequires: pkgconfig(libavcodec)
|
|
BuildRequires: pkgconfig(libavutil)
|
|
BuildRequires: pkgconfig(libcdio)
|
|
BuildRequires: pkgconfig(libchromaprint) >= 1.4
|
|
BuildRequires: pkgconfig(libgpod-1.0) >= 0.7.92
|
|
BuildRequires: pkgconfig(libmtp) >= 1.0
|
|
BuildRequires: pkgconfig(libmygpo-qt)
|
|
BuildRequires: pkgconfig(libpulse)
|
|
BuildRequires: pkgconfig(libxml-2.0)
|
|
BuildRequires: pkgconfig(protobuf)
|
|
BuildRequires: pkgconfig(QJson)
|
|
BuildRequires: pkgconfig(Qt5Core)
|
|
BuildRequires: pkgconfig(Qt5Gui)
|
|
BuildRequires: pkgconfig(Qt5Concurrent)
|
|
BuildRequires: pkgconfig(Qt5Xml)
|
|
BuildRequires: pkgconfig(Qt5Widgets)
|
|
BuildRequires: pkgconfig(Qt5Network)
|
|
BuildRequires: pkgconfig(Qt5Sql)
|
|
BuildRequires: pkgconfig(Qt5OpenGL)
|
|
BuildRequires: pkgconfig(Qt5X11Extras)
|
|
BuildRequires: pkgconfig(Qt5DBus)
|
|
BuildRequires: pkgconfig(Qt5Test)
|
|
|
|
BuildRequires: pkgconfig(openssl3.3)
|
|
|
|
BuildRequires: pkgconfig(libprojectM)
|
|
BuildRequires: git-core
|
|
|
|
# For Google Drive and Amazon Cloud integration
|
|
BuildRequires: pkgconfig(libsparsehash)
|
|
%if %{with plf}
|
|
BuildRequires: pkgconfig(libspotify) >= 12.1.45
|
|
BuildRequires: protobuf-static-devel
|
|
%endif
|
|
BuildRequires: pkgconfig(taglib) >= 1.8
|
|
BuildRequires: pkgconfig(x11)
|
|
Requires: libprojectm-data
|
|
#Requires: qt4-database-plugin-sqlite
|
|
Requires: gstreamer%{gstapi}-flac
|
|
Requires: gstreamer%{gstapi}-plugins-ugly
|
|
Suggests: gstreamer%{gstapi}-decoders-audio
|
|
Suggests: gstreamer%{gstapi}-faac
|
|
Suggests: gstreamer%{gstapi}-faad
|
|
Suggests: gstreamer%{gstapi}-lame
|
|
# Needed to be able to mount ipod/iphone/ipad (not tested locally) but it's also pulling gvfs
|
|
# which is need at least to mount mtp devices (tested locally)
|
|
Suggests: gvfs-iphone
|
|
|
|
%description
|
|
Clementine is a modern music player and library organiser. Clementine is
|
|
a port of Amarok 1.4, with some features rewritten to take advantage of
|
|
Qt5.
|
|
Features:
|
|
* Search and play your local music library.
|
|
* Listen to internet radio from Last.fm, SomaFM and Magnatune.
|
|
* Tabbed playlists, import and export M3U, XSPF, PLS and ASX.
|
|
* Visualisations from projectM.
|
|
* Transcode music into MP3, Ogg Vorbis, Ogg Speex, FLAC or AAC.
|
|
* Edit tags on MP3 and OGG files, organize your music.
|
|
* Download missing album cover art from Last.fm.
|
|
* Remote control using a Wii Remote, MPRIS or the command-line.
|
|
* Copy music to your iPod, iPhone, MTP or mass-storage USB player.
|
|
* Queue manage.
|
|
|
|
%files
|
|
%doc Changelog COPYING README.md
|
|
%config(noreplace) %{_sysconfdir}/%{oname}/%{oname}.conf
|
|
%{_bindir}/%{name}
|
|
%{_bindir}/%{name}-tagreader
|
|
%if %{with plf}
|
|
%{_bindir}/%{name}-spotifyblob
|
|
%endif
|
|
#{_datadir}/kde4/services/%{name}-*.protocol
|
|
%{_datadir}/kservices5/%{name}-*.protocol
|
|
%{_datadir}/metainfo/*.appdata.xml
|
|
%{_datadir}/applications/*.desktop
|
|
%{_iconsdir}/hicolor/*/apps/*.png
|
|
%{_iconsdir}/hicolor/scalable/apps/org.clementine_player.Clementine.svg
|
|
%{_datadir}/%{name}/projectm-presets/*
|
|
|
|
%prep
|
|
%setup -qn %{oname}-%{version}-%{gitrelease}-%{shortcommit}
|
|
#apply_patches
|
|
%patch9 -p1
|
|
|
|
# Fix perms
|
|
find . -name "*.hpp" -o -name "*.h" -o -name ".cpp" |xargs chmod 0644
|
|
|
|
#sed -i -e '/INCLUDE_GIT_REVISION/s/\ ON/\ OFF/g' \
|
|
# -e '/HAS_GIT_REVISION/s/\_ON/\ OFF/g' \
|
|
# -e '/CLEMENTINE_VERSION_PATCH/s/0/1/' \
|
|
# -e '/CLEMENTINE_VERSION_PRERELEASE/d' \
|
|
# cmake/Version.cmake
|
|
|
|
%build
|
|
%cmake_qt5 \
|
|
-DBUNDLE_PROJECTM_PRESETS=ON \
|
|
-DBUILD_WERROR=OFF
|
|
|
|
%make VERBOSE=1
|
|
|
|
|
|
%install
|
|
%makeinstall_std -C build
|
|
|
|
install -m 644 -D %{SOURCE1} %{buildroot}%{_sysconfdir}/%{oname}/%{oname}.conf
|
|
|
|
%if %{with plf}
|
|
# Ugly hack, not sure why those directory trees appear
|
|
rm -rf %{buildroot}/tmp/*
|
|
rm -rf %{buildroot}/build/spotify/*
|
|
rm -rf %{buildroot}/builddir/build/BUILD/clementine-20180812/build/spotify/*/blob
|
|
%endif
|
|
|