Merge pull request #250171 from rnhmjoj/pr-qute

qutebrowser: 2.5.4 -> 3.0.0

authored by

Michele Guerini Rocco and committed by
GitHub
ad0bbaf1 032895db

+23 -53
+21 -51
pkgs/applications/networking/browsers/qutebrowser/default.nix
··· 1 - { stdenv, lib, fetchurl, fetchzip, fetchFromGitHub, python3 2 , wrapQtAppsHook, glib-networking 3 , asciidoc, docbook_xml_dtd_45, docbook_xsl, libxml2 4 , libxslt, gst_all_1 ? null ··· 8 , pipewireSupport ? stdenv.isLinux 9 , pipewire 10 , qtwayland 11 - , mkDerivationWith ? null 12 - , qtbase ? null 13 - , qtwebengine ? null 14 - , wrapGAppsHook ? null 15 , enableWideVine ? false 16 , widevine-cdm 17 - }: let 18 - isQt6 = mkDerivationWith == null; 19 20 - python3Packages = python3.pkgs; 21 pdfjs = let 22 version = "3.9.179"; 23 in ··· 27 stripRoot = false; 28 }; 29 30 - backendPackage = 31 - if backend == "webengine" then if isQt6 then python3Packages.pyqt6-webengine else python3Packages.pyqtwebengine else 32 - if backend == "webkit" then python3Packages.pyqt5_with_qtwebkit else 33 - throw '' 34 - Unknown qutebrowser backend "${backend}". 35 - Valid choices are qtwebengine (recommended) or qtwebkit. 36 - ''; 37 - 38 - buildPythonApplication = if isQt6 then python3Packages.buildPythonApplication else mkDerivationWith python3Packages.buildPythonApplication; 39 - 40 pname = "qutebrowser"; 41 - version = if isQt6 then "unstable-2023-04-18" else "2.5.4"; 42 in 43 44 assert withMediaPlayback -> gst_all_1 != null; 45 - assert isQt6 -> backend != "webkit"; 46 47 - buildPythonApplication { 48 inherit pname version; 49 - 50 - src = if isQt6 then 51 - # comes from the master branch of upstream 52 - # https://github.com/qutebrowser/qutebrowser/issues/7202 53 - # https://github.com/qutebrowser/qutebrowser/discussions/7628 54 - fetchFromGitHub { 55 - owner = "qutebrowser"; 56 - repo = "qutebrowser"; 57 - rev = "d4cafc0019a4a5574caa11966fc40ede89076d26"; 58 - hash = "sha256-Ma79EPvnwmQkeXEG9aSnD/Vt1DGhK2JX9dib7uARH8M="; 59 - } 60 - # the release tarballs are different from the git checkout! 61 - else fetchurl { 62 url = "https://github.com/qutebrowser/qutebrowser/releases/download/v${version}/${pname}-${version}.tar.gz"; 63 - hash = "sha256-pGCyICUn5CpnDCbSJdn6ZBfQkswfFvOpXnvJXdicGrE="; 64 }; 65 66 # Needs tox ··· 77 nativeBuildInputs = [ 78 wrapQtAppsHook wrapGAppsHook asciidoc 79 docbook_xml_dtd_45 docbook_xsl libxml2 libxslt 80 - ] 81 - ++ lib.optional isQt6 python3Packages.pygments; 82 83 - propagatedBuildInputs = with python3Packages; ([ 84 - pyyaml backendPackage jinja2 pygments 85 # scripts and userscripts libs 86 tldextract beautifulsoup4 87 readability-lxml pykeepass stem 88 pynacl 89 # extensive ad blocking 90 adblock 91 - ] 92 - ++ lib.optional (pythonOlder "3.9") importlib-resources 93 - ++ lib.optional stdenv.isLinux qtwayland 94 ); 95 96 patches = [ ··· 99 100 dontWrapGApps = true; 101 dontWrapQtApps = true; 102 - 103 - preConfigure = lib.optionalString isQt6 '' 104 - python scripts/asciidoc2html.py 105 - ''; 106 107 postPatch = '' 108 substituteInPlace qutebrowser/misc/quitter.py --subst-var-by qutebrowser "$out/bin/qutebrowser" ··· 141 makeWrapperArgs+=( 142 "''${gappsWrapperArgs[@]}" 143 "''${qtWrapperArgs[@]}" 144 - --add-flags '--backend ${backend}' 145 - --set QUTE_QTWEBENGINE_VERSION_OVERRIDE "${lib.getVersion qtwebengine}" 146 - ${lib.optionalString isQt6 ''--set QUTE_QT_WRAPPER "PyQt6"''} 147 - ${lib.optionalString (pipewireSupport && backend == "webengine") ''--prefix LD_LIBRARY_PATH : ${libPath}''} 148 ${lib.optionalString enableWideVine ''--add-flags "--qt-flag widevine-path=${widevine-cdm}/share/google/chrome/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so"''} 149 ) 150 ''; ··· 153 homepage = "https://github.com/qutebrowser/qutebrowser"; 154 description = "Keyboard-focused browser with a minimal GUI"; 155 license = licenses.gpl3Plus; 156 - platforms = if enableWideVine then [ "x86_64-linux" ] else backendPackage.meta.platforms; 157 maintainers = with maintainers; [ jagajaga rnhmjoj ebzzry dotlambda nrdxp ]; 158 }; 159 }
··· 1 + { stdenv, lib, fetchurl, fetchzip, python3 2 , wrapQtAppsHook, glib-networking 3 , asciidoc, docbook_xml_dtd_45, docbook_xsl, libxml2 4 , libxslt, gst_all_1 ? null ··· 8 , pipewireSupport ? stdenv.isLinux 9 , pipewire 10 , qtwayland 11 + , qtbase 12 + , qtwebengine 13 + , wrapGAppsHook 14 , enableWideVine ? false 15 , widevine-cdm 16 + }: 17 18 + let 19 pdfjs = let 20 version = "3.9.179"; 21 in ··· 25 stripRoot = false; 26 }; 27 28 pname = "qutebrowser"; 29 + version = "3.0.0"; 30 in 31 32 assert withMediaPlayback -> gst_all_1 != null; 33 + assert lib.assertMsg (backend != "webkit") '' 34 + Support for the QtWebKit backend has been removed. 35 + Please remove the `backend = "webkit"` option from your qutebrowser override. 36 + ''; 37 38 + python3.pkgs.buildPythonApplication { 39 inherit pname version; 40 + src = fetchurl { 41 url = "https://github.com/qutebrowser/qutebrowser/releases/download/v${version}/${pname}-${version}.tar.gz"; 42 + hash = "sha256-Oer0p/DwUfOejUCgSCSkMvLLAjNyJx51qgN7bcQQ2Pw="; 43 }; 44 45 # Needs tox ··· 56 nativeBuildInputs = [ 57 wrapQtAppsHook wrapGAppsHook asciidoc 58 docbook_xml_dtd_45 docbook_xsl libxml2 libxslt 59 + python3.pkgs.pygments 60 + ]; 61 62 + propagatedBuildInputs = with python3.pkgs; ([ 63 + pyyaml pyqtwebengine jinja2 pygments 64 # scripts and userscripts libs 65 tldextract beautifulsoup4 66 readability-lxml pykeepass stem 67 pynacl 68 # extensive ad blocking 69 adblock 70 + ] ++ lib.optional stdenv.isLinux qtwayland 71 ); 72 73 patches = [ ··· 76 77 dontWrapGApps = true; 78 dontWrapQtApps = true; 79 80 postPatch = '' 81 substituteInPlace qutebrowser/misc/quitter.py --subst-var-by qutebrowser "$out/bin/qutebrowser" ··· 114 makeWrapperArgs+=( 115 "''${gappsWrapperArgs[@]}" 116 "''${qtWrapperArgs[@]}" 117 + ${lib.optionalString pipewireSupport ''--prefix LD_LIBRARY_PATH : ${libPath}''} 118 ${lib.optionalString enableWideVine ''--add-flags "--qt-flag widevine-path=${widevine-cdm}/share/google/chrome/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so"''} 119 ) 120 ''; ··· 123 homepage = "https://github.com/qutebrowser/qutebrowser"; 124 description = "Keyboard-focused browser with a minimal GUI"; 125 license = licenses.gpl3Plus; 126 + platforms = if enableWideVine then [ "x86_64-linux" ] else qtwebengine.meta.platforms; 127 maintainers = with maintainers; [ jagajaga rnhmjoj ebzzry dotlambda nrdxp ]; 128 }; 129 }
+1
pkgs/top-level/aliases.nix
··· 1488 quake3game = throw "'quake3game' has been renamed to/replaced by 'ioquake3'"; # Converted to throw 2022-02-22 1489 quaternion-git = throw "quaternion-git has been removed in favor of the stable version 'quaternion'"; # Added 2020-04-09 1490 quilter = throw "quilter has been removed from nixpkgs, as it was unmaintained"; # Added 2021-08-03 1491 qvim = throw "qvim has been removed"; # Added 2020-08-31 1492 qweechat = throw "qweechat has been removed because it was broken"; # Added 2021-03-08 1493 qwt6 = throw "'qwt6' has been renamed to/replaced by 'libsForQt5.qwt'"; # Converted to throw 2022-02-22
··· 1488 quake3game = throw "'quake3game' has been renamed to/replaced by 'ioquake3'"; # Converted to throw 2022-02-22 1489 quaternion-git = throw "quaternion-git has been removed in favor of the stable version 'quaternion'"; # Added 2020-04-09 1490 quilter = throw "quilter has been removed from nixpkgs, as it was unmaintained"; # Added 2021-08-03 1491 + qutebrowser-qt6 = throw "'qutebrowser-qt6' has been replaced by 'qutebrowser', since the the qt5 version has been removed"; # Added 2023-08-19 1492 qvim = throw "qvim has been removed"; # Added 2020-08-31 1493 qweechat = throw "qweechat has been removed because it was broken"; # Added 2021-03-08 1494 qwt6 = throw "'qwt6' has been renamed to/replaced by 'libsForQt5.qwt'"; # Converted to throw 2022-02-22
+1 -2
pkgs/top-level/all-packages.nix
··· 34909 withXineBackend = true; 34910 }; 34911 34912 - qutebrowser = libsForQt5.callPackage ../applications/networking/browsers/qutebrowser { }; 34913 - qutebrowser-qt6 = callPackage ../applications/networking/browsers/qutebrowser { 34914 inherit (qt6Packages) qtbase qtwebengine wrapQtAppsHook qtwayland; 34915 }; 34916
··· 34909 withXineBackend = true; 34910 }; 34911 34912 + qutebrowser = callPackage ../applications/networking/browsers/qutebrowser { 34913 inherit (qt6Packages) qtbase qtwebengine wrapQtAppsHook qtwayland; 34914 }; 34915