From dab195957bdd75eba49ee3d08adc5ff805d4f497 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sat, 27 Jun 2020 15:11:05 +0200 Subject: gnu: xpra: Upgrade to 4.0.2. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/xorg.scm (xpra)[version]: Upgrade. [source]: Add patch. [inputs]: Adjust to use Python 3 dependencies. [arguments]: Use Python 3, add phases to patch hardcoded binary paths. * gnu/local.mk (dist_patch_DATA): Add patch. * gnu/packages/patches/xpra-4.0.1-systemd-run.patch: New file. Signed-off-by: Ludovic Courtès --- gnu/packages/patches/xpra-4.0.1-systemd-run.patch | 34 +++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 gnu/packages/patches/xpra-4.0.1-systemd-run.patch (limited to 'gnu/packages/patches/xpra-4.0.1-systemd-run.patch') diff --git a/gnu/packages/patches/xpra-4.0.1-systemd-run.patch b/gnu/packages/patches/xpra-4.0.1-systemd-run.patch new file mode 100644 index 0000000000..1ea11830a5 --- /dev/null +++ b/gnu/packages/patches/xpra-4.0.1-systemd-run.patch @@ -0,0 +1,34 @@ +Disable systemd-run if the command is not found. + +diff -Naur xpra-4.0.1/xpra/scripts/main.py xpra-4.0.1.patched/xpra/scripts/main.py +--- xpra-4.0.1/xpra/scripts/main.py 2020-05-17 18:12:15.000000000 +0200 ++++ xpra-4.0.1.patched/xpra/scripts/main.py 2020-06-01 12:12:18.500257507 +0200 +@@ -312,16 +312,18 @@ + if not is_systemd_pid1(): + return False + #test it: +- cmd = ["systemd-run", "--quiet", "--user", "--scope", "--", "true"] +- proc = Popen(cmd, stdin=None, stdout=None, stderr=None, shell=False) +- r = pollwait(proc, timeout=1) +- if r is None: +- try: +- proc.terminate() +- except Exception: +- pass +- return r==0 +- ++ try: ++ cmd = ["systemd-run", "--quiet", "--user", "--scope", "--", "true"] ++ proc = Popen(cmd, stdin=None, stdout=None, stderr=None, shell=False) ++ r = pollwait(proc, timeout=1) ++ if r is None: ++ try: ++ proc.terminate() ++ except Exception: ++ pass ++ return r==0 ++ except FileNotFoundError: ++ return False + + def run_mode(script_file, error_cb, options, args, mode, defaults): + #configure default logging handler: -- cgit v1.2.3