about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorDmitry Kalinkin <dmitry.kalinkin@gmail.com>2020-06-13 19:54:28 -0400
committerGitHub <noreply@github.com>2020-06-13 19:54:28 -0400
commitf97f334a6c1b610d8dbcadb15e9c982090c664ad (patch)
tree1e9c0aa7b3867e666c9bdbc220e71f5f54431274 /pkgs
parent4361446b99f1a2c76ce30b18ac1496cef1a1c767 (diff)
parent458d86fd9ce01637f6a4a80559aaf207862a9dd5 (diff)
downloadnixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar.gz
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar.bz2
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar.lz
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar.xz
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.tar.zst
nixlib-f97f334a6c1b610d8dbcadb15e9c982090c664ad.zip
Merge pull request #89821 from veprbl/pr/clementine_1_4_0rc1
clementine: 1.3.1 -> 1.4.0rc1, switch to Qt 5, fix build
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/audio/clementine/clementine-spotify-blob-remove-from-build.patch21
-rw-r--r--pkgs/applications/audio/clementine/default.nix41
-rw-r--r--pkgs/development/libraries/liblastfm/default.nix15
-rw-r--r--pkgs/top-level/all-packages.nix2
4 files changed, 29 insertions, 50 deletions
diff --git a/pkgs/applications/audio/clementine/clementine-spotify-blob-remove-from-build.patch b/pkgs/applications/audio/clementine/clementine-spotify-blob-remove-from-build.patch
deleted file mode 100644
index 226536a13ba7..000000000000
--- a/pkgs/applications/audio/clementine/clementine-spotify-blob-remove-from-build.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 23070d9..83b6772 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -275,8 +275,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)
-@@ -434,7 +432,6 @@ if(HAVE_BREAKPAD)
- endif(HAVE_BREAKPAD)
- 
- if(HAVE_SPOTIFY_BLOB)
--  add_subdirectory(ext/clementine-spotifyblob)
- endif(HAVE_SPOTIFY_BLOB)
- 
- if(HAVE_MOODBAR)
diff --git a/pkgs/applications/audio/clementine/default.nix b/pkgs/applications/audio/clementine/default.nix
index 15d0f92b76aa..0c1690f1462a 100644
--- a/pkgs/applications/audio/clementine/default.nix
+++ b/pkgs/applications/audio/clementine/default.nix
@@ -1,4 +1,5 @@
-{ stdenv, fetchFromGitHub, fetchpatch, boost, cmake, chromaprint, gettext, gst_all_1, liblastfm
+{ stdenv, mkDerivation, fetchFromGitHub, fetchpatch, boost, cmake, chromaprint, gettext, gst_all_1, liblastfm
+, qtbase, qtx11extras
 , taglib, fftw, glew, qjson, sqlite, libgpod, libplist, usbmuxd, libmtp
 , libpulseaudio, gvfs, libcdio, libechonest, libspotify, pcre, projectm, protobuf
 , qca2, pkgconfig, sparsehash, config, makeWrapper, gst_plugins }:
@@ -9,30 +10,17 @@ let
   withCD = config.clementine.cd or true;
   withCloud = config.clementine.cloud or true;
 
-  version = "1.3.1";
+  version = "1.4.0rc1";
 
   src = fetchFromGitHub {
     owner = "clementine-player";
     repo = "Clementine";
     rev = version;
-    sha256 = "0i3jkfs8dbfkh47jq3cnx7pip47naqg7w66vmfszk4d8vj37j62j";
+    sha256 = "1rqk0hrsn8f8bjk0j0vq1af0ygy6xx7qi9fw0jjw2cmj6kzckyi2";
   };
 
   patches = [
     ./clementine-spotify-blob.patch
-    # Required so as to avoid adding libspotify as a build dependency (as it is
-    # unfree and thus would prevent us from having a free package).
-    ./clementine-spotify-blob-remove-from-build.patch
-    (fetchpatch {
-      # Fix w/gcc7
-      url = "https://github.com/clementine-player/Clementine/pull/5630.patch";
-      sha256 = "0px7xp1m4nvrncx8sga1qlxppk562wrk2qqk19iiry84nxg20mk4";
-    })
-    (fetchpatch {
-      # Fixes compilation with chromaprint >= 1.4
-      url = "https://github.com/clementine-player/Clementine/commit/d3ea0c8482dfd3f6264a30cfceb456076d76e6cd.patch";
-      sha256 = "1ifrs5aqdzw16jbnf0z1ilir20chdnr9k5n21r99miq9hzjpbh12";
-    })
   ];
 
   nativeBuildInputs = [ cmake pkgconfig ];
@@ -54,6 +42,8 @@ let
     protobuf
     qca2
     qjson
+    qtbase
+    qtx11extras
     sqlite
     taglib
   ]
@@ -71,7 +61,7 @@ let
       -e 's,libprotobuf.a,protobuf,g'
   '';
 
-  free = stdenv.mkDerivation {
+  free = mkDerivation {
     pname = "clementine-free";
     inherit version;
     inherit src patches nativeBuildInputs postPatch;
@@ -79,7 +69,14 @@ let
     # gst_plugins needed for setup-hooks
     buildInputs = buildInputs ++ [ makeWrapper ] ++ gst_plugins;
 
-    cmakeFlags = [ "-DUSE_SYSTEM_PROJECTM=ON" ];
+    preConfigure = ''
+      rm -rf ext/{,lib}clementine-spotifyblob
+    '';
+
+    cmakeFlags = [
+      "-DUSE_SYSTEM_PROJECTM=ON"
+      "-DSPOTIFY_BLOB=OFF"
+    ];
 
     enableParallelBuilding = true;
 
@@ -100,15 +97,11 @@ let
   };
 
   # Unfree Spotify blob for Clementine
-  unfree = stdenv.mkDerivation {
+  unfree = mkDerivation {
     pname = "clementine-blob";
     inherit version;
     # Use the same patches and sources as Clementine
-    inherit src nativeBuildInputs postPatch;
-
-    patches = [
-      ./clementine-spotify-blob.patch
-    ];
+    inherit src nativeBuildInputs patches postPatch;
 
     buildInputs = buildInputs ++ [ libspotify makeWrapper ];
     # Only build and install the Spotify blob
diff --git a/pkgs/development/libraries/liblastfm/default.nix b/pkgs/development/libraries/liblastfm/default.nix
index 62409bb7f649..762e707528a6 100644
--- a/pkgs/development/libraries/liblastfm/default.nix
+++ b/pkgs/development/libraries/liblastfm/default.nix
@@ -1,4 +1,5 @@
-{ stdenv, fetchurl, qt4, pkgconfig, libsamplerate, fftwSinglePrec, which, cmake
+{ stdenv, fetchurl, pkgconfig, which, cmake
+, fftwSinglePrec, libsamplerate, qtbase
 , darwin }:
 
 let version = "1.1.0"; in
@@ -14,16 +15,22 @@ stdenv.mkDerivation rec {
     sha256 = "1j34xc30vg7sfszm2jx9mlz9hy7p1l929fka9wnfcpbib8gfi43x";
   };
 
+  postPatch = ''
+    substituteInPlace CMakeLists.txt \
+      --replace 'find_package(Qt5Core QUIET)' \
+                'find_package(Qt5 REQUIRED COMPONENTS Core Network Sql Test Xml)'
+  '';
+
   prefixKey = "--prefix ";
-  propagatedBuildInputs = [ qt4 libsamplerate fftwSinglePrec ];
   nativeBuildInputs = [ pkgconfig which cmake ];
-  buildInputs = stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.SystemConfiguration;
+  buildInputs = [ fftwSinglePrec libsamplerate qtbase ]
+    ++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.SystemConfiguration;
 
   meta = with stdenv.lib; {
     homepage = "https://github.com/lastfm/liblastfm";
     repositories.git = "git://github.com/lastfm/liblastfm.git";
     description = "Official LastFM library";
-    inherit (qt4.meta) platforms;
+    platforms = platforms.unix;
     maintainers =  [ maintainers.phreedom ];
     license = licenses.gpl3;
   };
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 05f58b3a246f..934575e01ecf 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -13072,7 +13072,7 @@ in
 
   liblastfmSF = callPackage ../development/libraries/liblastfmSF { };
 
-  liblastfm = callPackage ../development/libraries/liblastfm { };
+  liblastfm = libsForQt5.callPackage ../development/libraries/liblastfm { };
 
   liblcf = callPackage ../development/libraries/liblcf { };