Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

Merge pull request #222176 from SuperSamus/caffeine-ng

caffeine-ng: 4.0.2 -> 4.2.0

authored by Emily and committed by GitHub 7514c56c 2cd6171b

+55 -44
+30 -43
pkgs/tools/X11/caffeine-ng/default.nix
··· 1 - { buildPythonApplication 2 - , fetchPypi 3 , gobject-introspection 4 - , gtk3 5 , lib 6 - , libappindicator-gtk3 7 , libnotify 8 - , click 9 - , dbus-python 10 - , ewmh 11 - , pulsectl 12 - , pygobject3 13 - , pyxdg 14 - , setproctitle 15 - , python3 16 , procps 17 , xset 18 , xautolock 19 , xscreensaver 20 , xfce 21 - , glib 22 - , setuptools-scm 23 , wrapGAppsHook 24 }: 25 26 - let 27 - click_7 = click.overridePythonAttrs (old: rec { 28 - version = "7.1.2"; 29 - src = old.src.override { 30 - inherit version; 31 - hash = "sha256-0rUlXHxjSbwb0eWeCM0SrLvWPOZJ8liHVXg6qU37axo="; 32 - }; 33 - disabledTests = [ "test_bytes_args" ]; # https://github.com/pallets/click/commit/6e05e1fa1c2804 34 - }); 35 - in buildPythonApplication rec { 36 pname = "caffeine-ng"; 37 - version = "4.0.2"; 38 - format = "setuptools"; 39 40 - src = fetchPypi { 41 - inherit pname version; 42 - hash = "sha256-umIjXJ0et6Pi5Ejj96Q+ZhiKS+yj7bsgb4uQW6Ym6rU="; 43 }; 44 45 - nativeBuildInputs = [ wrapGAppsHook glib gobject-introspection setuptools-scm ]; 46 47 buildInputs = [ 48 - libappindicator-gtk3 49 libnotify 50 - gtk3 51 ]; 52 53 - pythonPath = [ 54 - click_7 55 dbus-python 56 ewmh 57 pulsectl 58 pygobject3 59 - pyxdg 60 setproctitle 61 ]; 62 63 - doCheck = false; # There are no tests. 64 dontWrapGApps = true; 65 - strictDeps = false; 66 67 - postInstall = '' 68 - cp -r share $out/ 69 - cp -r caffeine/assets/icons $out/share/ 70 71 - # autostart file 72 - ln -s $out/${python3.sitePackages}/etc $out/etc 73 74 - glib-compile-schemas --strict $out/share/glib-2.0/schemas 75 ''; 76 77 preFixup = '' ··· 86 maintainers = with maintainers; [ marzipankaiser ]; 87 description = "Status bar application to temporarily inhibit screensaver and sleep mode"; 88 homepage = "https://codeberg.org/WhyNotHugo/caffeine-ng"; 89 license = licenses.gpl3; 90 platforms = platforms.linux; 91 };
··· 1 + { fetchFromGitea 2 + , meson 3 + , ninja 4 + , pkg-config 5 + , scdoc 6 , gobject-introspection 7 , lib 8 + , libayatana-appindicator 9 , libnotify 10 + , python3Packages 11 , procps 12 , xset 13 , xautolock 14 , xscreensaver 15 , xfce 16 , wrapGAppsHook 17 }: 18 19 + python3Packages.buildPythonApplication rec { 20 pname = "caffeine-ng"; 21 + version = "4.2.0"; 22 + format = "other"; 23 24 + src = fetchFromGitea { 25 + domain = "codeberg.org"; 26 + owner = "WhyNotHugo"; 27 + repo = pname; 28 + rev = "v${version}"; 29 + sha256 = "sha256-uYzLRZ+6ZgIwhSuJWRBpLYHgonX7sFXgUZid0V26V0Q="; 30 }; 31 32 + nativeBuildInputs = [ gobject-introspection meson ninja pkg-config wrapGAppsHook ]; 33 34 buildInputs = [ 35 + libayatana-appindicator 36 libnotify 37 ]; 38 39 + pythonPath = with python3Packages; [ 40 + click 41 dbus-python 42 ewmh 43 pulsectl 44 pygobject3 45 + scdoc 46 setproctitle 47 ]; 48 49 dontWrapGApps = true; 50 51 + patches = [ 52 + ./fix-build.patch 53 + ]; 54 55 + postPatch = '' 56 + echo "${version}" > version 57 + ''; 58 59 + postInstall = '' 60 + glib-compile-schemas $out/share/glib-2.0/schemas 61 ''; 62 63 preFixup = '' ··· 72 maintainers = with maintainers; [ marzipankaiser ]; 73 description = "Status bar application to temporarily inhibit screensaver and sleep mode"; 74 homepage = "https://codeberg.org/WhyNotHugo/caffeine-ng"; 75 + changelog = "https://codeberg.org/WhyNotHugo/caffeine-ng/src/tag/v${version}/CHANGELOG.rst"; 76 license = licenses.gpl3; 77 platforms = platforms.linux; 78 };
+24
pkgs/tools/X11/caffeine-ng/fix-build.patch
···
··· 1 + diff --git a/meson.build b/meson.build 2 + index 3e4f9ea..5b82861 100644 3 + --- a/meson.build 4 + +++ b/meson.build 5 + @@ -2,10 +2,6 @@ project( 6 + 'caffeine-ng', 7 + version: run_command('./scripts/read_version.sh', check: true).stdout().strip(), 8 + meson_version: '>=0.63.0', 9 + - default_options: [ 10 + - # The default can yield broken results. 11 + - 'python.install_env=auto' 12 + - ] 13 + ) 14 + 15 + dependency('pygobject-3.0') 16 + @@ -82,7 +78,7 @@ configure_file( 17 + 18 + install_data( 19 + 'share/applications/caffeine.desktop', 20 + - install_dir: '/etc/xdg/autostart', 21 + + install_dir: join_paths(get_option('sysconfdir'), 'xdg/autostart'), 22 + ) 23 + 24 + install_data(
+1 -1
pkgs/top-level/all-packages.nix
··· 39547 39548 caffeWithCuda = caffe.override { cudaSupport = true; }; 39549 39550 - caffeine-ng = python3Packages.callPackage ../tools/X11/caffeine-ng { }; 39551 39552 cntk = callPackage ../applications/science/math/cntk { 39553 stdenv = gcc7Stdenv;
··· 39547 39548 caffeWithCuda = caffe.override { cudaSupport = true; }; 39549 39550 + caffeine-ng = callPackage ../tools/X11/caffeine-ng { }; 39551 39552 cntk = callPackage ../applications/science/math/cntk { 39553 stdenv = gcc7Stdenv;