Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / games / rare / default.nix
blob5253d78be5757dba3a8529d6b82fe6d161f693d6
1 { lib
2 , fetchFromGitHub
3 , buildPythonApplication
4 , qt5
5 , legendary-gl
6 , pypresence
7 , pyqt5
8 , python
9 , qtawesome
10 , requests
11 , typing-extensions
14 buildPythonApplication rec {
15   pname = "rare";
16   version = "1.10.3";
18   src = fetchFromGitHub {
19     owner = "Dummerle";
20     repo = "Rare";
21     rev = "refs/tags/${version}";
22     hash = "sha256-7KER9gCpqjEKikQTVHsvwX6efCb9L0ut6OBjjLBW2tI=";
23   };
25   nativeBuildInputs = [
26     qt5.wrapQtAppsHook
27   ];
29   propagatedBuildInputs = [
30     legendary-gl
31     pypresence
32     pyqt5
33     qtawesome
34     requests
35     typing-extensions
36   ];
38   patches = [
39     # Not able to run pythonRelaxDepsHook because of https://github.com/NixOS/nixpkgs/issues/198342
40     ./legendary-gl-version.patch
41   ];
43   dontWrapQtApps = true;
45   postInstall = ''
46     install -Dm644 misc/rare.desktop -t $out/share/applications/
47     install -Dm644 $out/${python.sitePackages}/rare/resources/images/Rare.png $out/share/pixmaps/rare.png
48   '';
50   preFixup = ''
51     makeWrapperArgs+=("''${qtWrapperArgs[@]}")
52   '';
54   # Project has no tests
55   doCheck = false;
57   meta = with lib; {
58     description = "GUI for Legendary, an Epic Games Launcher open source alternative";
59     homepage = "https://github.com/Dummerle/Rare";
60     maintainers = with maintainers; [ wolfangaukang ];
61     license = licenses.gpl3Only;
62     platforms = platforms.linux;
63   };