From patchwork Tue May 7 21:54:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Diego Nicola Barbato X-Patchwork-Id: 13927 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 7554516FCB; Tue, 7 May 2019 22:55:09 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 5899716FC8 for ; Tue, 7 May 2019 22:55:08 +0100 (BST) Received: from localhost ([127.0.0.1]:55278 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hO83H-0005BY-MF for patchwork@mira.cbaines.net; Tue, 07 May 2019 17:55:07 -0400 Received: from eggs.gnu.org ([209.51.188.92]:48605) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hO83F-0005BS-N2 for guix-patches@gnu.org; Tue, 07 May 2019 17:55:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hO83E-0003di-GW for guix-patches@gnu.org; Tue, 07 May 2019 17:55:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:46312) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hO83E-0003ce-4L for guix-patches@gnu.org; Tue, 07 May 2019 17:55:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hO83C-0005f3-BK for guix-patches@gnu.org; Tue, 07 May 2019 17:55:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#35493] [PATCH 1/3] gnu: slim: Allow customisation of Xorg display. Resent-From: Diego Nicola Barbato Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 07 May 2019 21:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35493 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?utf-8?q?Court=C3=A8s?= Received: via spool by 35493-submit@debbugs.gnu.org id=B35493.155726608621735 (code B ref 35493); Tue, 07 May 2019 21:55:02 +0000 Received: (at 35493) by debbugs.gnu.org; 7 May 2019 21:54:46 +0000 Received: from localhost ([127.0.0.1]:59856 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hO82w-0005eV-3v for submit@debbugs.gnu.org; Tue, 07 May 2019 17:54:46 -0400 Received: from mout02.posteo.de ([185.67.36.66]:55781) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hO82u-0005eH-0m for 35493@debbugs.gnu.org; Tue, 07 May 2019 17:54:45 -0400 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 185732400E5 for <35493@debbugs.gnu.org>; Tue, 7 May 2019 23:54:38 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1557266078; bh=5kbp5cDrvGpcUDXdHhbevILR+AQVpl7JurJij2Q21Ks=; h=From:To:Cc:Subject:Date:From; b=LJfWJPfCeUzXQZZG2sNURhYJNAOVypxVUIAO7XnOhS9z9QeuD/tEH4Fk6KqkV/Rku LafkE6XJc+bGslE02T48HL05JmX6EV0p1eYL/YTWRufyL5tn+KAvgRJA+XL+KOg5uy WtefhpmuaSv5NRyQ3nQKUBPjqqi0gQ/xOhVGwnKJ596QF3d2Mha9xye9KgQje8GQDl 04FjFlQSyFiOuY3IKy3LRveY5yveD6aDDS7nfYqn248vsI3QbP9we0xn1HAGwl05zY WsOjZEKvvzONxTgy0OjdD1lrwDVCPG6trdVAYcMGMngYxGV6xQk4/o5qKzhhW2LCP/ IUF7MOKJfSSpQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 44zD0Y2RmSz9rxD; Tue, 7 May 2019 23:54:37 +0200 (CEST) From: Diego Nicola Barbato References: <871s1kad42.fsf@GlaDOS.home> <87zho88yh4.fsf@GlaDOS.home> <87muk0m13s.fsf@gnu.org> <874l67rf8o.fsf@GlaDOS.home> <87woj25pxy.fsf@gnu.org> Date: Tue, 07 May 2019 23:54:36 +0200 In-Reply-To: <87woj25pxy.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Tue, 07 May 2019 15:55:53 +0200") Message-ID: <87tve6orqb.fsf@GlaDOS.home> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 35493@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Hi Ludo, Ludovic Courtès writes: > Hi Diego, > > Diego Nicola Barbato skribis: > >> Ludovic Courtès writes: > > [...] > >>> The patch LGTM. Just one question: did you submit it upstream (is there >>> still an upstream?), and if so, could we add the URL of upstream’s >>> tracking software or an indication about the submission? >> >> I did not submit it upstream (the most likely candidate seems to be this >> [0] even though it is not mentioned e.g. on the ArchWiki), since the >> general consensus seems to be that the project has been abandoned. > > That makes sense. > > I’ve applied the 3 patches and confirmed that > gnu/system/examples/vm-image.tmpl, which uses SLiM, still works > correctly. > > However, I’ve noticed that this changes the name of the default Shepherd > service from ‘xorg-server’ to ‘xorg-server-vt7’. > > What about generating an ‘xorg-server’ Shepherd service that would > depend on all the ‘xorg-server-vtN’ services? Hmm that wouldn’t be > entirely equivalent: ‘herd start xorg-server’ would start them all, but > ‘herd stop xorg-server’ wouldn’t stop any of them. > > Perhaps a simple fix is, when there’s only one server launched, to have > the Shepherd service provide both ‘xorg-server-vtN’ and ‘xorg-server’. > Or to special-case vt7 such that the service for vt7 provides both > ‘xorg-server’ and ‘xorg-server-vt7’. > > Thoughts? How about changing the default value of vt to #f and having the Shepherd service provide ‘xorg-server-vtN’ only if vt is set to "vtN" and ‘xorg-server’ otherwise. That way the name of the default Shepherd service would not change. I have attached a patch that does just that. If we apply it we will also have to update the documentation to reflect the change of vt's default value. Regards, Diego From 14d0106f53ee17aea8f176745bf6dd5d8a748965 Mon Sep 17 00:00:00 2001 From: Diego Nicola Barbato Date: Tue, 7 May 2019 22:22:48 +0200 Subject: [PATCH] services: slim: Make default Shepherd service provide 'xorg-server'. Commit 6426a8fb6c changed the name of the default Shepherd service from 'xorg-server' to 'xorg-server-vt7'. This patch changes it back. * gnu/services/xorg.scm (define-module): Use module (ice-9 format). ()[vt]: Change default value to #f. (slim-shepherd-service)[shepherd-service][provision]: Provide 'xorg-server-vtN' if vt is set to "vtN" and 'xorg-server' if vt is #f. --- gnu/services/xorg.scm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm index 65e9d48915..81e38665c9 100644 --- a/gnu/services/xorg.scm +++ b/gnu/services/xorg.scm @@ -52,6 +52,7 @@ #:use-module (srfi srfi-9) #:use-module (srfi srfi-26) #:use-module (ice-9 match) + #:use-module (ice-9 format) #:export (xorg-configuration xorg-configuration? xorg-configuration-modules @@ -493,7 +494,7 @@ desktop session from the system or user profile will be used." (display slim-configuration-display (default ":0")) (vt slim-configuration-vt - (default "vt7")) + (default #f)) (sessreg slim-configuration-sessreg (default sessreg))) @@ -510,7 +511,8 @@ desktop session from the system or user profile will be used." (xauth (slim-configuration-xauth config)) (startx (xorg-start-command (slim-configuration-xorg config))) (display (slim-configuration-display config)) - (vt (slim-configuration-vt config)) + (vt? (slim-configuration-vt config)) + (vt (or vt? "vt7")) (shepherd (slim-configuration-shepherd config)) (theme-name (slim-configuration-theme-name config)) (sessreg (slim-configuration-sessreg config)) @@ -549,8 +551,8 @@ reboot_cmd " shepherd "/sbin/reboot\n" (list (shepherd-service (documentation "Xorg display server") - (provision (list (symbol-append 'xorg-server- - (string->symbol vt)))) + (provision (list (string->symbol + (format #f "xorg-server~@[-~a~]" vt?)))) (requirement '(user-processes host-name udev)) (start #~(lambda () -- 2.21.0