arandr: fix build (#540391)

This commit is contained in:
Stefan Frijters
2026-07-11 13:29:52 +00:00
committed by GitHub
2 changed files with 20 additions and 7 deletions

View File

@@ -1,7 +1,8 @@
--- setup.py 2025-04-01 11:24:54.530984662 +0000
+++ setup.py 2025-04-01 13:54:46.961341548 +0000
@@ -111,9 +111,11 @@
diff --git a/setup.py b/setup.py
index 6e295c8..048db19 100755
--- a/setup.py
+++ b/setup.py
@@ -111,9 +111,11 @@ class build_man(NoOptionCommand):
info('compressing man page to %s', gzfile)
if not self.dry_run:
@@ -13,3 +14,6 @@
+ compressed.write(manpage)
+ compressed.close()
+ file.close()
class update_translator_credits(NoOptionCommand):
description = 'Examine the git history to produce an updated metadata file.'

View File

@@ -1,6 +1,7 @@
{
lib,
fetchFromGitLab,
fetchpatch,
python3Packages,
gobject-introspection,
gsettings-desktop-schemas,
@@ -30,9 +31,17 @@ buildPythonApplication (finalAttrs: {
hash = "sha256-nQtfOKAnWKsy2DmvtRGJa4+Y9uGgX41BeHpd9m4d9YA=";
};
# patch to set mtime=0 on setup.py
patches = [ ./gzip-timestamp-fix.patch ];
patchFlags = [ "-p0" ];
patches = [
# patch to set mtime=0 on setup.py
./gzip-timestamp-fix.patch
# fixes build with setuptools 81+, while keeping it backwards compatible
(fetchpatch {
name = "arandr-0.1.11-setuptools-81.patch";
url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/x11-misc/arandr/files/arandr-0.1.11-setuptools-81.patch";
hash = "sha256-b9U8b4rdkN5lWDVpv50szaVS0rAZVSy7q6IXNVLvq3A=";
})
];
nativeBuildInputs = [
gobject-introspection