caffeine-ng: 4.0.2 -> 4.2.0
This commit is contained in:
parent
ce5e4a6ef2
commit
a03a8db8b9
3 changed files with 56 additions and 45 deletions
|
@ -1,77 +1,63 @@
|
|||
{ buildPythonApplication
|
||||
, fetchPypi
|
||||
{ fetchFromGitea
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
, scdoc
|
||||
, gobject-introspection
|
||||
, gtk3
|
||||
, lib
|
||||
, libappindicator-gtk3
|
||||
, libayatana-appindicator
|
||||
, libnotify
|
||||
, click
|
||||
, dbus-python
|
||||
, ewmh
|
||||
, pulsectl
|
||||
, pygobject3
|
||||
, pyxdg
|
||||
, setproctitle
|
||||
, python3
|
||||
, python3Packages
|
||||
, procps
|
||||
, xset
|
||||
, xautolock
|
||||
, xscreensaver
|
||||
, xfce
|
||||
, glib
|
||||
, setuptools-scm
|
||||
, wrapGAppsHook
|
||||
}:
|
||||
|
||||
let
|
||||
click_7 = click.overridePythonAttrs (old: rec {
|
||||
version = "7.1.2";
|
||||
src = old.src.override {
|
||||
inherit version;
|
||||
hash = "sha256-0rUlXHxjSbwb0eWeCM0SrLvWPOZJ8liHVXg6qU37axo=";
|
||||
};
|
||||
disabledTests = [ "test_bytes_args" ]; # https://github.com/pallets/click/commit/6e05e1fa1c2804
|
||||
});
|
||||
in buildPythonApplication rec {
|
||||
python3Packages.buildPythonApplication rec {
|
||||
pname = "caffeine-ng";
|
||||
version = "4.0.2";
|
||||
format = "setuptools";
|
||||
version = "4.2.0";
|
||||
format = "other";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-umIjXJ0et6Pi5Ejj96Q+ZhiKS+yj7bsgb4uQW6Ym6rU=";
|
||||
src = fetchFromGitea {
|
||||
domain = "codeberg.org";
|
||||
owner = "WhyNotHugo";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-uYzLRZ+6ZgIwhSuJWRBpLYHgonX7sFXgUZid0V26V0Q=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ wrapGAppsHook glib gobject-introspection setuptools-scm ];
|
||||
nativeBuildInputs = [ gobject-introspection meson ninja pkg-config wrapGAppsHook ];
|
||||
|
||||
buildInputs = [
|
||||
libappindicator-gtk3
|
||||
libayatana-appindicator
|
||||
libnotify
|
||||
gtk3
|
||||
];
|
||||
|
||||
pythonPath = [
|
||||
click_7
|
||||
pythonPath = with python3Packages; [
|
||||
click
|
||||
dbus-python
|
||||
ewmh
|
||||
pulsectl
|
||||
pygobject3
|
||||
pyxdg
|
||||
scdoc
|
||||
setproctitle
|
||||
];
|
||||
|
||||
doCheck = false; # There are no tests.
|
||||
dontWrapGApps = true;
|
||||
strictDeps = false;
|
||||
|
||||
patches = [
|
||||
./fix-build.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
echo "${version}" > version
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
cp -r share $out/
|
||||
cp -r caffeine/assets/icons $out/share/
|
||||
|
||||
# autostart file
|
||||
ln -s $out/${python3.sitePackages}/etc $out/etc
|
||||
|
||||
glib-compile-schemas --strict $out/share/glib-2.0/schemas
|
||||
glib-compile-schemas $out/share/glib-2.0/schemas
|
||||
'';
|
||||
|
||||
preFixup = ''
|
||||
|
@ -86,6 +72,7 @@ in buildPythonApplication rec {
|
|||
maintainers = with maintainers; [ marzipankaiser ];
|
||||
description = "Status bar application to temporarily inhibit screensaver and sleep mode";
|
||||
homepage = "https://codeberg.org/WhyNotHugo/caffeine-ng";
|
||||
changelog = "https://codeberg.org/WhyNotHugo/caffeine-ng/src/tag/v${version}/CHANGELOG.rst";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
|
|
24
pkgs/tools/X11/caffeine-ng/fix-build.patch
Normal file
24
pkgs/tools/X11/caffeine-ng/fix-build.patch
Normal file
|
@ -0,0 +1,24 @@
|
|||
diff --git a/meson.build b/meson.build
|
||||
index 3e4f9ea..5b82861 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -2,10 +2,6 @@ project(
|
||||
'caffeine-ng',
|
||||
version: run_command('./scripts/read_version.sh', check: true).stdout().strip(),
|
||||
meson_version: '>=0.63.0',
|
||||
- default_options: [
|
||||
- # The default can yield broken results.
|
||||
- 'python.install_env=auto'
|
||||
- ]
|
||||
)
|
||||
|
||||
dependency('pygobject-3.0')
|
||||
@@ -82,7 +78,7 @@ configure_file(
|
||||
|
||||
install_data(
|
||||
'share/applications/caffeine.desktop',
|
||||
- install_dir: '/etc/xdg/autostart',
|
||||
+ install_dir: join_paths(get_option('sysconfdir'), 'xdg/autostart'),
|
||||
)
|
||||
|
||||
install_data(
|
|
@ -39503,7 +39503,7 @@ with pkgs;
|
|||
|
||||
caffeWithCuda = caffe.override { cudaSupport = true; };
|
||||
|
||||
caffeine-ng = python3Packages.callPackage ../tools/X11/caffeine-ng { };
|
||||
caffeine-ng = callPackage ../tools/X11/caffeine-ng { };
|
||||
|
||||
cntk = callPackage ../applications/science/math/cntk {
|
||||
stdenv = gcc7Stdenv;
|
||||
|
|
Loading…
Reference in a new issue