sobota, 5 października 2013

Long time, no see

lightdm-1.6.2-1 is there. And so is Xephyr 1.12.4-6.2+b2.
The latter works with the usual procedure. The former does change the procedure a bit. The patch referring to removing stale files does not apply at all. I just don't use it any more... and as far as I know there has been some activity in the lightdm project regarding removing any stale files at runtime. So now only the patch adding the "common-vt" option is required.
Below is what I applied:

diff --git a/src/lightdm.c b/src/lightdm.c
index 7f67ea7..840aee1 100644
--- a/src/lightdm.c
+++ b/src/lightdm.c
@@ -1056,6 +1056,8 @@ main (int argc, char **argv)
         config_set_boolean (config_get_instance (), "LightDM", "start-default-seat", TRUE);
     if (!config_has_key (config_get_instance (), "LightDM", "minimum-vt"))
         config_set_integer (config_get_instance (), "LightDM", "minimum-vt", 7);
+    if (!config_has_key (config_get_instance (), "LightDM", "common-vt"))
+        config_set_boolean (config_get_instance (), "LightDM", "common-vt", FALSE);
     if (!config_has_key (config_get_instance (), "LightDM", "guest-account-script"))
         config_set_string (config_get_instance (), "LightDM", "guest-account-script", "guest-account");
     if (!config_has_key (config_get_instance (), "LightDM", "greeter-user"))
diff --git a/src/vt.c b/src/vt.c
index 62839d9..810e73e 100644
--- a/src/vt.c
+++ b/src/vt.c
@@ -117,15 +117,23 @@ vt_get_min (void)
 gint
 vt_get_unused (void)
 {
+    static gint common_number = -1;
+
+    gboolean common_vt;
     gint number;

     if (getuid () != 0)
         return -1;

+    common_vt = config_get_boolean (config_get_instance (), "LightDM", "common-vt");
+    if (common_vt && common_number > 0)
+    return common_number;
+
     number = vt_get_min ();
     while (vt_is_used (number))
         number++;
 
+    common_number = number;
     return number;
 }



And it works, as of October 5th, 2013.

sobota, 25 maja 2013

lightdm 1.6.0-3

OK, the patches almost apply; below there is the new patch.
Confirmed, works.

Description: <short summary of the patch>
 Xephyr-multiseat requires that all X servers are run on the same vt.
 .
 lightdm (1.6.0-3) unstable; urgency=low
 .
   * debian/control:
     - drop valac-0.18 dependency for now since it's not available in sid
       anyway.                                                   closes: #707176
Author: Yves-Alexis Perez <corsac@debian.org>
Bug-Debian: http://bugs.debian.org/707176

---
The information above should follow the Patch Tagging Guidelines, please
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: <vendor|upstream|other>, <url of original patch>
Bug: <url in upstream bugtracker>
Bug-Debian: http://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: <no|not-needed|url proving that it has been forwarded>
Reviewed-By: <name and email of someone who approved the patch>
Last-Update: <YYYY-MM-DD>

--- lightdm-1.6.0.orig/src/lightdm.c
+++ lightdm-1.6.0/src/lightdm.c
@@ -974,6 +974,8 @@ main (int argc, char **argv)
         config_set_boolean (config_get_instance (), "LightDM", "start-default-seat", TRUE);
     if (!config_has_key (config_get_instance (), "LightDM", "minimum-vt"))
         config_set_integer (config_get_instance (), "LightDM", "minimum-vt", 7);
+    if (!config_has_key (config_get_instance (), "LightDM", "common-vt"))
+        config_set_boolean (config_get_instance (), "LightDM", "common-vt", FALSE);
     if (!config_has_key (config_get_instance (), "LightDM", "guest-account-script"))
         config_set_string (config_get_instance (), "LightDM", "guest-account-script", "guest-account");
     if (!config_has_key (config_get_instance (), "LightDM", "greeter-user"))
--- lightdm-1.6.0.orig/src/xserver-local.c
+++ lightdm-1.6.0/src/xserver-local.c
@@ -318,9 +318,13 @@ got_signal_cb (Process *process, int sig
 static void
 stopped_cb (Process *process, XServerLocal *server)
 {
+    guint display_number;
+    gchar *path;
+
     g_debug ("X server stopped");

-    xserver_local_release_display_number (xserver_get_display_number (XSERVER (server)));
+    display_number = xserver_get_display_number (XSERVER (server));
+    xserver_local_release_display_number (display_number);
  
     if (xserver_get_authority (XSERVER (server)) && server->priv->authority_file)
     {
@@ -345,6 +349,10 @@ stopped_cb (Process *process, XServerLoc
         plymouth_quit (FALSE);
     }

+    path = g_strdup_printf ("/tmp/.X%d-lock", display_number);
+    g_unlink (path);
+    g_free (path);
+
     DISPLAY_SERVER_CLASS (xserver_local_parent_class)->stop (DISPLAY_SERVER (server));
 }

--- lightdm-1.6.0.orig/src/vt.c
+++ lightdm-1.6.0/src/vt.c
@@ -125,15 +125,23 @@ vt_get_min (void)
 gint
 vt_get_unused (void)
 {
+    static gint common_number = -1;
+
+    gboolean common_vt;
     gint number;

     if (getuid () != 0)
         return -1;

+    common_vt = config_get_boolean (config_get_instance (), "LightDM", "common-vt");
+    if (common_vt && common_number > 0)
+    return common_number;
+
     number = vt_get_min ();
     while (vt_is_used (number))
         number++;
 
+    common_number = number;
     return number;
 }

czwartek, 16 maja 2013

Jessie is here!

The king has died, long live the king! Wheezy is released to be the next, rock-solid stable Debian. And so it is time to move to the new testing.

Jessie is here, with ligthdm 1.2.3-1. The usual patches do apply, although with some fuzz, but "patch" still handles this ok.

Confirmed, works.

środa, 27 lutego 2013

Another dist-upgrade

Debian wheezy as of 27th February 2013 with udev 175-7.1 works.

However, my Xephyr-seat-X scripts sometimes do not function correctly: it turns out, that when the Xephyr is run, there is no DISPLAY :0. I solved the problem twofold: 1) I added a "sleep 5" before Xephyr is invoked and 2) used "Option" "NoLogo" "true" entry in my xorg.conf's "Device" section for nvidia.
I think that drawing a logo and keeping it visible for some time creates some delays, so probably it is better not to draw it.