Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / libraries / liblastfm / default.nix
blob7dcc3b0d0cc06bdb79648b40cd4ce8b679f94a82
1 { lib, stdenv, fetchFromGitHub, fetchpatch, pkg-config, which, cmake
2 , fftwSinglePrec, libsamplerate, qtbase
3 , darwin }:
5 stdenv.mkDerivation rec {
6   pname = "liblastfm-unstable";
7   version = "2019-08-23";
9   src = fetchFromGitHub {
10     owner = "lastfm";
11     repo = "liblastfm";
12     rev = "2ce2bfe1879227af8ffafddb82b218faff813db9";
13     sha256 = "1crih9xxf3rb109aqw12bjqv47z28lvlk2dpvyym5shf82nz6yd0";
14   };
16   patches = [(fetchpatch {
17     url = "https://github.com/lastfm/liblastfm/commit/9c5d072b55f2863310e40291677e6397e9cbc3c2.patch";
18     name = "0001-Remove-deprecated-staging-server-and-fix-test-for-QT5-at-Ubuntu-19.10.patch";
19     sha256 = "04r14prydxshjgfws3pjajjmp2msszhjjs1mjh8s66yg29vq620l";
20   })];
22   nativeBuildInputs = [ pkg-config which cmake ];
23   buildInputs = [ fftwSinglePrec libsamplerate qtbase ]
24     ++ lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.SystemConfiguration;
26   env.NIX_CFLAGS_COMPILE = lib.optionalString (stdenv.cc.isGNU && lib.versionAtLeast stdenv.cc.version "11") "-std=c++11";
28   dontWrapQtApps = true;
30   meta = with lib; {
31     homepage = "https://github.com/lastfm/liblastfm";
32     description = "Official LastFM library";
33     platforms = platforms.unix;
34     maintainers = [ ];
35     license = licenses.gpl3;
36   };