diff --git a/pkgs/by-name/xp/xpra/fix-122159.patch b/pkgs/by-name/xp/xpra/fix-122159.patch index ae1b27e2bda5..ceb90cc2af10 100644 --- a/pkgs/by-name/xp/xpra/fix-122159.patch +++ b/pkgs/by-name/xp/xpra/fix-122159.patch @@ -1,6 +1,6 @@ --- a/xpra/scripts/main.py +++ b/xpra/scripts/main.py -@@ -536,13 +536,7 @@ +@@ -526,13 +526,7 @@ "upgrade", "upgrade-seamless", "upgrade-desktop", "encoder", "runner", ) and not display_is_remote and options.daemon and use_systemd_run(options.systemd_run): @@ -8,9 +8,9 @@ - # inject it into the command line if we have to: argv = list(cmdline) - if argv[0].find("python") < 0: -- major, minor = sys.version_info.major, sys.version_info.minor -- python = which("python%i.%i" % (major, minor)) or which("python%i" % major) or which("python") or "python" -- argv.insert(0, python) +- from xpra.platform.paths import get_python_execfile_command +- for arg in reversed(get_python_execfile_command()): +- argv.insert(0, arg) return systemd_run_wrap(mode, argv, options.systemd_run_args, user=getuid() != 0) configure_env(options.env) configure_logging(options, mode) diff --git a/pkgs/by-name/xp/xpra/package.nix b/pkgs/by-name/xp/xpra/package.nix index bcd5776b7d21..da038f7556a2 100644 --- a/pkgs/by-name/xp/xpra/package.nix +++ b/pkgs/by-name/xp/xpra/package.nix @@ -1,6 +1,7 @@ { lib, fetchFromGitHub, + nix-update-script, pkg-config, runCommand, writeText, @@ -104,14 +105,14 @@ let in effectiveBuildPythonApplication rec { pname = "xpra"; - version = "6.4.4"; + version = "6.5.3"; format = "setuptools"; src = fetchFromGitHub { owner = "Xpra-org"; repo = "xpra"; tag = "v${version}"; - hash = "sha256-zDI6xksviTjsfsh5OJdkif24BGPW9zfDsxATC98eeX0="; + hash = "sha256-UDKnkynWoS1feUBRRHXl7emksUmufBL16gmVFslMHpM="; }; patches = [ @@ -120,7 +121,7 @@ effectiveBuildPythonApplication rec { ]; postPatch = lib.optionalString stdenv.hostPlatform.isLinux '' - substituteInPlace xpra/platform/posix/features.py \ + substituteInPlace xpra/scripts/config.py \ --replace-fail "/usr/bin/xdg-open" "${xdg-utils}/bin/xdg-open" patchShebangs --build fs/bin/build_cuda_kernels.py @@ -290,7 +291,7 @@ effectiveBuildPythonApplication rec { passthru = { inherit xf86videodummy; - updateScript = ./update.sh; + updateScript = nix-update-script { }; }; meta = { diff --git a/pkgs/by-name/xp/xpra/update.sh b/pkgs/by-name/xp/xpra/update.sh deleted file mode 100755 index c1b408a0beef..000000000000 --- a/pkgs/by-name/xp/xpra/update.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env nix-shell -#!nix-shell -i bash -p curl perl common-updater-scripts - -version=$(curl https://xpra.org/src/ | perl -ne 'print "$1\n" if /xpra-([[:digit:].]+)\./' | sort -V | tail -n1) -update-source-version xpra "$version"