gnu: clementine: Remove Spotify downloader.

Clementine has a button in the preference menu that allows downloading a
binary blob to add support for Spofify.  Let's remove this button.  It turns
out this is the only part of the code base that uses crypto++, let's remove
this dependency too.

* gnu/packages/music.scm (clementine)[arguments]: Remove crypto++ support. Set
HAVE_SPOTIFY_DOWNLOADER to FALSE.
[inputs]: Remove crypto++ input.
* gnu/packages/patches/clementine-remove-crypto++-dependency.patch: New file.
* gnu/local.mk (dist_patch_DATA): Add it.

Signed-off-by: Leo Famulari <leo@famulari.name>
This commit is contained in:
Pierre Langlois 2018-02-08 22:03:36 +00:00 committed by Leo Famulari
parent a48b877e60
commit af414f34fb
No known key found for this signature in database
GPG key ID: 2646FA30BACA7F08
3 changed files with 29 additions and 9 deletions

View file

@ -580,6 +580,7 @@ dist_patch_DATA = \
%D%/packages/patches/chmlib-inttypes.patch \ %D%/packages/patches/chmlib-inttypes.patch \
%D%/packages/patches/clang-libc-search-path.patch \ %D%/packages/patches/clang-libc-search-path.patch \
%D%/packages/patches/clang-3.8-libc-search-path.patch \ %D%/packages/patches/clang-3.8-libc-search-path.patch \
%D%/packages/patches/clementine-remove-crypto++-dependency.patch \
%D%/packages/patches/clementine-use-openssl.patch \ %D%/packages/patches/clementine-use-openssl.patch \
%D%/packages/patches/clisp-remove-failing-test.patch \ %D%/packages/patches/clisp-remove-failing-test.patch \
%D%/packages/patches/clucene-pkgconfig.patch \ %D%/packages/patches/clucene-pkgconfig.patch \

View file

@ -226,18 +226,19 @@ (define-public clementine
"sha2" ;; Replaced by openssl. "sha2" ;; Replaced by openssl.
"taglib" "taglib"
"tinysvcmdns"))) "tinysvcmdns")))
(patches (search-patches "clementine-use-openssl.patch")))) (patches (search-patches "clementine-use-openssl.patch"
"clementine-remove-crypto++-dependency.patch"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(arguments (arguments
'(#:test-target "clementine_test" '(#:test-target "clementine_test"
#:configure-flags #:configure-flags
(let ((crypto (assoc-ref %build-inputs "crypto++"))) (list ;; Requires unpackaged "projectm"
(list "-DENABLE_VISUALISATIONS=OFF" ; requires unpackaged "projectm" "-DENABLE_VISUALISATIONS=OFF"
"-DCRYPTOPP_FOUND=TRUE" ;; Otherwise it may try to download a non-free library at run-time.
(string-append "-DCRYPTOPP_INCLUDE_DIRS=" crypto "/include") ;; TODO In an origin snippet, remove the code that performs the
(string-append "-DCRYPTOPP_LIBRARY_DIRS=" crypto "/lib") ;; download.
(string-append "-DCRYPTOPP_LIBRARIES=" crypto "/lib/libcryptopp.a") "-DHAVE_SPOTIFY_DOWNLOADER=FALSE"
"-DUSE_SYSTEM_SHA2=TRUE")) "-DUSE_SYSTEM_SHA2=TRUE")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'install 'wrap-program (add-after 'install 'wrap-program
@ -254,7 +255,6 @@ (define-public clementine
(inputs (inputs
`(("boost" ,boost) `(("boost" ,boost)
("chromaprint" ,chromaprint) ("chromaprint" ,chromaprint)
("crypto++" ,crypto++)
("fftw" ,fftw) ("fftw" ,fftw)
("glib" ,glib) ("glib" ,glib)
("glu" ,glu) ("glu" ,glu)

View file

@ -0,0 +1,19 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3202b8b..473ecb9 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -279,14 +279,6 @@ optional_component(LIBPULSE ON "Pulse audio integration"
optional_component(VISUALISATIONS ON "Visualisations")
-if(NOT HAVE_SPOTIFY_BLOB AND NOT CRYPTOPP_FOUND)
- message(FATAL_ERROR "Either crypto++ must be available or the non-GPL Spotify "
- "code must be compiled in")
-elseif(CRYPTOPP_FOUND)
- set(HAVE_CRYPTOPP ON)
- set(HAVE_SPOTIFY_DOWNLOADER ON)
-endif()
-
# Find DBus if it's enabled
if (HAVE_DBUS)
find_package(Qt5 COMPONENTS DBus)