gnu: Add durden.
* gnu/packages/arcan.scm (durden): New variable. * gnu/packages/patches/durden-shadow-arcan.patch: New file. * gnu/local.mk: Register it. Change-Id: I3ea34563c74c227eed40f4ad50d23713c45ce70b Signed-off-by: Ludovic Courtès <ludo@gnu.org>master
parent
ce2d140c5b
commit
43719864cf
|
@ -1120,6 +1120,7 @@ dist_patch_DATA = \
|
||||||
%D%/packages/patches/dune-common-skip-failing-tests.patch \
|
%D%/packages/patches/dune-common-skip-failing-tests.patch \
|
||||||
%D%/packages/patches/dune-grid-add-missing-include-cassert.patch \
|
%D%/packages/patches/dune-grid-add-missing-include-cassert.patch \
|
||||||
%D%/packages/patches/dune-istl-fix-solver-playground.patch \
|
%D%/packages/patches/dune-istl-fix-solver-playground.patch \
|
||||||
|
%D%/packages/patches/durden-shadow-arcan.patch \
|
||||||
%D%/packages/patches/dvd+rw-tools-add-include.patch \
|
%D%/packages/patches/dvd+rw-tools-add-include.patch \
|
||||||
%D%/packages/patches/dynaconf-unvendor-deps.patch \
|
%D%/packages/patches/dynaconf-unvendor-deps.patch \
|
||||||
%D%/packages/patches/dyninst-fix-glibc-compatibility.patch \
|
%D%/packages/patches/dyninst-fix-glibc-compatibility.patch \
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
;;; GNU Guix --- Functional package management for GNU
|
;;; GNU Guix --- Functional package management for GNU
|
||||||
;;; Copyright © 2019 L p R n d n <guix@lprndn.info>
|
;;; Copyright © 2019 L p R n d n <guix@lprndn.info>
|
||||||
;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
|
;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
|
||||||
;;; Copyright © 2023 Ahmad Draidi <a.r.draidi@redscript.org>
|
;;; Copyright © 2023, 2024 Ahmad Draidi <a.r.draidi@redscript.org>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -20,6 +20,7 @@
|
||||||
|
|
||||||
(define-module (gnu packages arcan)
|
(define-module (gnu packages arcan)
|
||||||
#:use-module (guix build-system cmake)
|
#:use-module (guix build-system cmake)
|
||||||
|
#:use-module (guix build-system copy)
|
||||||
#:use-module (guix build-system meson)
|
#:use-module (guix build-system meson)
|
||||||
#:use-module (guix build-system gnu)
|
#:use-module (guix build-system gnu)
|
||||||
#:use-module (guix gexp)
|
#:use-module (guix gexp)
|
||||||
|
@ -27,8 +28,10 @@
|
||||||
#:use-module ((guix licenses) #:prefix license:)
|
#:use-module ((guix licenses) #:prefix license:)
|
||||||
#:use-module (guix packages)
|
#:use-module (guix packages)
|
||||||
#:use-module (guix utils)
|
#:use-module (guix utils)
|
||||||
|
#:use-module (gnu packages)
|
||||||
#:use-module (gnu packages audio)
|
#:use-module (gnu packages audio)
|
||||||
#:use-module (gnu packages autotools)
|
#:use-module (gnu packages autotools)
|
||||||
|
#:use-module (gnu packages base)
|
||||||
#:use-module (gnu packages bash)
|
#:use-module (gnu packages bash)
|
||||||
#:use-module (gnu packages compression)
|
#:use-module (gnu packages compression)
|
||||||
#:use-module (gnu packages databases)
|
#:use-module (gnu packages databases)
|
||||||
|
@ -183,6 +186,74 @@ engine with a Lua scripting interface.")
|
||||||
"-DSTATIC_FREETYPE=off" "-DSHMIF_TUI_ACCEL=on")))))
|
"-DSTATIC_FREETYPE=off" "-DSHMIF_TUI_ACCEL=on")))))
|
||||||
(synopsis "Combined display server, multimedia framework and game engine (SDL)")))
|
(synopsis "Combined display server, multimedia framework and game engine (SDL)")))
|
||||||
|
|
||||||
|
(define-public durden
|
||||||
|
;; Match Arcan 0.6.3
|
||||||
|
(let ((commit "a8938b9c835f55bedc2c42aec4ddc5c9739eb949")
|
||||||
|
(revision "1"))
|
||||||
|
(package
|
||||||
|
(name "durden")
|
||||||
|
(version (git-version "0.6.1" revision commit))
|
||||||
|
(source
|
||||||
|
(origin
|
||||||
|
(method git-fetch)
|
||||||
|
(file-name (git-file-name name version))
|
||||||
|
(uri (git-reference
|
||||||
|
(url "https://github.com/letoram/durden")
|
||||||
|
(commit commit)))
|
||||||
|
(sha256
|
||||||
|
(base32 "1ybi6x2kwn597kjqycrqmlvp6z79yv2jfwzgx937wcckm55xlpvk"))
|
||||||
|
(patches (search-patches "durden-shadow-arcan.patch"))))
|
||||||
|
(build-system copy-build-system)
|
||||||
|
(arguments
|
||||||
|
(list
|
||||||
|
#:install-plan #~'(("durden/" "share/arcan/appl/durden/")
|
||||||
|
("util/" "share/arcan/appl/durden/util/")
|
||||||
|
("distr/durden" "bin/durden"))
|
||||||
|
#:phases #~(modify-phases %standard-phases
|
||||||
|
(add-after 'unpack 'patch-paths
|
||||||
|
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||||
|
(substitute* "distr/durden"
|
||||||
|
(("/usr/share/\\$applname")
|
||||||
|
(string-append (assoc-ref outputs "out")
|
||||||
|
"/share/arcan/appl"))
|
||||||
|
(("@ARCAN_STORE_PATH@")
|
||||||
|
(string-append (assoc-ref inputs "arcan")
|
||||||
|
"/bin/arcan"))
|
||||||
|
(("([\\([:blank:]]+)basename " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/basename "))
|
||||||
|
(("([\\([:blank:]]+)date " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/date "))
|
||||||
|
(("([\\([:blank:]]+)ln " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/ln "))
|
||||||
|
(("([\\([:blank:]]+)mkdir " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/mkdir "))
|
||||||
|
(("([\\([:blank:]]+)true; " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/true; "))
|
||||||
|
(("([\\([:blank:]]+)\\[ " _ separator)
|
||||||
|
(string-append separator
|
||||||
|
(assoc-ref inputs "coreutils")
|
||||||
|
"/bin/[ "))))))))
|
||||||
|
(inputs (list arcan coreutils))
|
||||||
|
(home-page "https://durden.arcan-fe.com/")
|
||||||
|
(synopsis "Desktop Environment for Arcan")
|
||||||
|
(description
|
||||||
|
"Durden is a desktop environment for the Arcan Display Server.
|
||||||
|
It serves both as a reference showcase on how to take advantage of some of the
|
||||||
|
features in Arcan, and as an entry to the advanced-user side of the desktop
|
||||||
|
environment spectrum.")
|
||||||
|
(license (list license:bsd-3 license:expat license:cc-by3.0
|
||||||
|
license:cc-by4.0 license:asl2.0)))))
|
||||||
|
|
||||||
(define-public xarcan
|
(define-public xarcan
|
||||||
(package
|
(package
|
||||||
(name "xarcan")
|
(name "xarcan")
|
||||||
|
|
|
@ -0,0 +1,42 @@
|
||||||
|
From 157524b7cb76c5044a27f4a9e373ee04a9da3c71 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Ahmad Draidi <a.r.draidi@redscript.org>
|
||||||
|
Date: Tue, 9 Apr 2024 18:26:52 +0400
|
||||||
|
Subject: [PATCH] Use arcan from setuid-programs if available
|
||||||
|
|
||||||
|
---
|
||||||
|
distr/durden | 10 ++++++++--
|
||||||
|
1 file changed, 8 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/distr/durden b/distr/durden
|
||||||
|
index ab431ce..8672556 100755
|
||||||
|
--- a/distr/durden
|
||||||
|
+++ b/distr/durden
|
||||||
|
@@ -1,5 +1,11 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
+if [ -n "$(command -v /run/setuid-programs/arcan 2>/dev/null)" ]; then
|
||||||
|
+ ARCAN_CMD="/run/setuid-programs/arcan"
|
||||||
|
+else
|
||||||
|
+ ARCAN_CMD="@ARCAN_STORE_PATH@"
|
||||||
|
+fi
|
||||||
|
+
|
||||||
|
arcan_base=${HOME}/.arcan
|
||||||
|
applname="$(basename $0)"
|
||||||
|
distargs=""
|
||||||
|
@@ -98,11 +104,11 @@ while true; do
|
||||||
|
starttime=$(date +%s)
|
||||||
|
|
||||||
|
if [ -d "${arcan_logpath}" ]; then
|
||||||
|
- if arcan ${distargs} -b "$applname" "$applname" "$@" >"${arcan_logpath}/${applname}_${starttime}.log" 2>&1; then
|
||||||
|
+ if "${ARCAN_CMD}" ${distargs} -b "$applname" "$applname" "$@" >"${arcan_logpath}/${applname}_${starttime}.log" 2>&1; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
- if arcan ${distargs} -b "$applname" "$applname" "$@"; then
|
||||||
|
+ if "${ARCAN_CMD}" ${distargs} -b "$applname" "$applname" "$@"; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
--
|
||||||
|
2.41.0
|
||||||
|
|
Reference in New Issue