Skip to content

Commit

Permalink
x11/gdm: Update to 42.0
Browse files Browse the repository at this point in the history
  • Loading branch information
neelchauhan committed Mar 22, 2022
1 parent ab52f5e commit f3439a4
Show file tree
Hide file tree
Showing 16 changed files with 77 additions and 213 deletions.
5 changes: 2 additions & 3 deletions x11/gdm/Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# Created by: Joe Marcus Clarke <marcus@FreeBSD.org>

PORTNAME= gdm
PORTVERSION= 41.3
PORTREVISION= 2
PORTVERSION= 42.0
CATEGORIES= x11 gnome
MASTER_SITES= GNOME/sources/${PORTNAME}/${PORTVERSION:C/^([0-9]+)\..*/\1/}
DIST_SUBDIR= gnome

MAINTAINER= gnome@FreeBSD.org
COMMENT= GNOME 3 display manager
COMMENT= GNOME display manager

LICENSE= GPLv2
LICENSE_FILE= ${WRKSRC}/COPYING
Expand Down
6 changes: 3 additions & 3 deletions x11/gdm/distinfo
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
TIMESTAMP = 1643405191
SHA256 (gnome/gdm-41.3.tar.xz) = bb0b650a7cea90f09a33284fbd02975315407efc18e814009852d1bcad3437d4
SIZE (gnome/gdm-41.3.tar.xz) = 807452
TIMESTAMP = 1647984111
SHA256 (gnome/gdm-42.0.tar.xz) = a328ac976937bec179971ff07829a1246b98ce724181c128ae32a0ba47ad3855
SIZE (gnome/gdm-42.0.tar.xz) = 811200
70 changes: 41 additions & 29 deletions x11/gdm/files/patch-daemon_gdm-local-display-factory.c
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
--- daemon/gdm-local-display-factory.c.orig 2022-01-12 14:15:56 UTC
--- daemon/gdm-local-display-factory.c.orig 2022-03-21 18:12:40 UTC
+++ daemon/gdm-local-display-factory.c
@@ -28,7 +28,9 @@
#include <glib-object.h>
@@ -29,10 +29,12 @@
#include <gio/gio.h>

#ifdef HAVE_UDEV
-#include <gudev/gudev.h>
+#undef HAVE_UDEV
#endif

+#ifdef WITH_SYSTEMD
#include <systemd/sd-login.h>
+#endif

#include "gdm-common.h"
#include "gdm-manager.h"
@@ -61,8 +63,10 @@ struct _GdmLocalDisplayFactory
@@ -68,8 +70,10 @@ struct _GdmLocalDisplayFactory
/* FIXME: this needs to be per seat? */
guint num_failures;

Expand All @@ -20,8 +24,8 @@
+#endif
guint seat_properties_changed_id;

gboolean seat0_graphics_check_timed_out;
@@ -94,9 +98,11 @@ static void on_display_status_changed
gboolean seat0_has_platform_graphics;
@@ -106,9 +110,11 @@ static gpointer local_display_factory_object = NULL;

static gboolean gdm_local_display_factory_sync_seats (GdmLocalDisplayFactory *factory);
static gpointer local_display_factory_object = NULL;
Expand All @@ -33,7 +37,7 @@

G_DEFINE_TYPE (GdmLocalDisplayFactory, gdm_local_display_factory, GDM_TYPE_DISPLAY_FACTORY)

@@ -233,9 +239,9 @@ struct GdmDisplayServerConfiguration {
@@ -245,9 +251,9 @@ struct GdmDisplayServerConfiguration {
const char *session_type;
} display_server_configuration[] = {
#ifdef ENABLE_WAYLAND_SUPPORT
Expand All @@ -45,23 +49,31 @@
{ NULL, NULL, NULL },
};

@@ -439,6 +445,7 @@ gdm_local_display_factory_create_transient_display (Gd
@@ -373,7 +379,6 @@ gdm_local_display_factory_create_transient_display (Gd
gboolean ret;
GdmDisplay *display = NULL;
gboolean is_initial = FALSE;
- const char *session_type;
g_autofree gchar *preferred_display_server = NULL;

g_return_val_if_fail (GDM_IS_LOCAL_DISPLAY_FACTORY (factory), FALSE);
@@ -451,6 +456,7 @@ gdm_local_display_factory_create_transient_display (Gd
return ret;
}

+#ifdef WITH_SYSTEMD
static void
finish_display_on_seat_if_waiting (GdmDisplayStore *display_store,
GdmDisplay *display,
@@ -493,6 +500,7 @@ on_session_registered_cb (GObject *gobject,
@@ -505,6 +511,7 @@ on_session_registered_cb (GObject *gobject,

finish_waiting_displays_on_seat (factory, "seat0");
}
+#endif

static void
on_display_status_changed (GdmDisplay *display,
@@ -540,7 +548,7 @@ on_display_status_changed (GdmDisplay *dis
@@ -552,7 +559,7 @@ on_display_status_changed (GdmDisplay *dis
* if there isn't one.
*/
if (is_local &&
Expand All @@ -70,7 +82,7 @@
/* reset num failures */
factory->num_failures = 0;

@@ -649,7 +657,9 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
@@ -741,7 +748,9 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
const char *legacy_session_types[] = { "x11", NULL };
GdmDisplayStore *store;
GdmDisplay *display = NULL;
Expand All @@ -80,48 +92,48 @@
gboolean wayland_enabled = FALSE, xorg_enabled = FALSE;
g_autofree gchar *preferred_display_server = NULL;
gboolean falling_back = FALSE;
@@ -679,7 +689,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
seat_supports_graphics = TRUE;
@@ -781,7 +790,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
seat_supports_graphics = FALSE;
}

- if (g_strcmp0 (seat_id, "seat0") == 0) {
+ if (g_strcmp0 (seat_id, SEAT_ID) == 0) {
is_seat0 = TRUE;

falling_back = factory->num_failures > 0;
@@ -767,6 +777,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
@@ -869,6 +878,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
return;
}

+#ifdef WITH_SYSTEMD
/* If we already have a login window, switch to it */
if (gdm_get_login_window_session_id (seat_id, &login_session_id)) {
GdmDisplay *display;
@@ -784,6 +795,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
@@ -886,6 +896,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
return;
}
}
+#endif

g_debug ("GdmLocalDisplayFactory: Adding display on seat %s", seat_id);

@@ -827,6 +839,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
@@ -929,6 +940,7 @@ ensure_display_for_seat (GdmLocalDisplayFactory *facto
return;
}

+#ifdef WITH_SYSTEMD
static void
delete_display (GdmLocalDisplayFactory *factory,
const char *seat_id) {
@@ -838,6 +851,7 @@ delete_display (GdmLocalDisplayFactory *factory,
@@ -940,6 +952,7 @@ delete_display (GdmLocalDisplayFactory *factory,
store = gdm_display_factory_get_display_store (GDM_DISPLAY_FACTORY (factory));
gdm_display_store_foreach_remove (store, lookup_by_seat_id, (gpointer) seat_id);
}
+#endif

static gboolean
gdm_local_display_factory_sync_seats (GdmLocalDisplayFactory *factory)
@@ -849,6 +863,8 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
@@ -951,6 +964,8 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
const char *seat;

g_debug ("GdmLocalDisplayFactory: enumerating seats from logind");
Expand All @@ -130,7 +142,7 @@
result = g_dbus_connection_call_sync (factory->connection,
"org.freedesktop.login1",
"/org/freedesktop/login1",
@@ -859,6 +875,18 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
@@ -961,6 +976,18 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
G_DBUS_CALL_FLAGS_NONE,
-1,
NULL, &error);
Expand All @@ -149,31 +161,31 @@

if (!result) {
g_warning ("GdmLocalDisplayFactory: Failed to issue method call: %s", error->message);
@@ -878,6 +906,7 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
@@ -980,6 +1007,7 @@ gdm_local_display_factory_sync_seats (GdmLocalDisplayF
return TRUE;
}

+#ifdef WITH_SYSTEMD
static void
on_seat_new (GDBusConnection *connection,
const gchar *sender_name,
@@ -989,6 +1018,7 @@ lookup_by_tty (const char *id,
@@ -1093,6 +1121,7 @@ lookup_by_tty (const char *id,

return g_strcmp0 (tty_to_check, tty_to_find) == 0;
}
+#endif

#if defined(ENABLE_USER_DISPLAY_SERVER)
static void
@@ -1166,6 +1196,7 @@ on_vt_changed (GIOChannel *source,
@@ -1295,6 +1324,7 @@ on_uevent (GUdevClient *client,
}
#endif

+#ifdef WITH_SYSTEMD
static void
gdm_local_display_factory_start_monitor (GdmLocalDisplayFactory *factory)
{
@@ -1215,10 +1246,12 @@ gdm_local_display_factory_start_monitor (GdmLocalDispl
@@ -1352,10 +1382,12 @@ gdm_local_display_factory_start_monitor (GdmLocalDispl
}
#endif
}
Expand All @@ -182,19 +194,19 @@
static void
gdm_local_display_factory_stop_monitor (GdmLocalDisplayFactory *factory)
{
+#ifdef WITH_SYSTEMD
if (factory->seat_new_id) {
g_dbus_connection_signal_unsubscribe (factory->connection,
factory->seat_new_id);
@@ -1244,6 +1277,7 @@ gdm_local_display_factory_stop_monitor (GdmLocalDispla
+#ifdef HAVE_UDEV
if (factory->uevent_handler_id) {
g_signal_handler_disconnect (factory->gudev_client, factory->uevent_handler_id);
factory->uevent_handler_id = 0;
@@ -1387,6 +1419,7 @@ gdm_local_display_factory_stop_monitor (GdmLocalDispla
factory->wait_to_finish_timeout_id = 0;
}
#endif
+#endif
}

static void
@@ -1298,7 +1332,9 @@ gdm_local_display_factory_start (GdmDisplayFactory *ba
@@ -1441,7 +1474,9 @@ gdm_local_display_factory_start (GdmDisplayFactory *ba
factory,
0);

Expand Down
11 changes: 1 addition & 10 deletions x11/gdm/files/patch-daemon_gdm-session-worker.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
--- daemon/gdm-session-worker.c.orig 2022-01-12 14:15:56 UTC
--- daemon/gdm-session-worker.c.orig 2022-03-21 18:12:40 UTC
+++ daemon/gdm-session-worker.c
@@ -28,9 +28,11 @@
#include <string.h>
Expand All @@ -22,15 +22,6 @@

#ifdef ENABLE_SYSTEMD_JOURNAL
#include <systemd/sd-journal.h>
@@ -94,7 +98,7 @@
#endif

#ifndef GDM_SESSION_DEFAULT_PATH
-#define GDM_SESSION_DEFAULT_PATH "/usr/local/bin:/usr/bin:/bin"
+#define GDM_SESSION_DEFAULT_PATH "%%LOCALBASE%%/bin:/usr/bin:/bin"
#endif

#ifndef GDM_SESSION_ROOT_UID
@@ -126,6 +130,10 @@ struct GdmSessionWorkerPrivate

int exit_code;
Expand Down
8 changes: 4 additions & 4 deletions x11/gdm/files/patch-daemon_main.c
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
--- daemon/main.c.orig 2022-01-12 14:15:56 UTC
--- daemon/main.c.orig 2022-03-21 18:12:40 UTC
+++ daemon/main.c
@@ -289,6 +289,7 @@ is_debug_set (void)
@@ -281,6 +281,7 @@ is_debug_set (void)
return debug;
}

+#ifdef HAVE_SIGWAITINFO
/* SIGUSR1 is used by the X server to tell us that we're ready, so
* block it. We'll unblock it in the worker thread in gdm-server.c
*/
@@ -301,6 +302,7 @@ block_sigusr1 (void)
@@ -293,6 +294,7 @@ block_sigusr1 (void)
sigaddset (&mask, SIGUSR1);
sigprocmask (SIG_BLOCK, &mask, NULL);
}
+#endif

int
main (int argc,
@@ -321,7 +323,9 @@ main (int argc,
@@ -313,7 +315,9 @@ main (int argc,
{ NULL }
};

Expand Down
6 changes: 3 additions & 3 deletions x11/gdm/files/patch-daemon_meson.build
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
--- daemon/meson.build.orig 2022-01-12 14:15:56 UTC
--- daemon/meson.build.orig 2022-03-21 18:12:40 UTC
+++ daemon/meson.build
@@ -128,6 +128,7 @@ endif
@@ -128,6 +128,7 @@ gdm_session_worker = executable('gdm-session-worker',
gdm_session_worker = executable('gdm-session-worker',
gdm_session_worker_src,
dependencies: gdm_session_worker_deps,
+ link_args : ['-lutil'],
include_directories: gdm_session_worker_includes,
install: true,
install_dir: get_option('libexecdir'),
@@ -207,6 +208,7 @@ endif
@@ -211,6 +212,7 @@ gdm_daemon = executable('gdm',
gdm_daemon = executable('gdm',
[ gdm_daemon_sources, gdm_daemon_gen_sources ],
dependencies: gdm_daemon_deps,
Expand Down
23 changes: 0 additions & 23 deletions x11/gdm/files/patch-data_61-gdm.rules.in

This file was deleted.

22 changes: 11 additions & 11 deletions x11/gdm/files/patch-data_Init.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- data/Init.in.orig 2022-01-12 14:15:56 UTC
--- data/Init.in.orig 2022-03-21 18:12:40 UTC
+++ data/Init.in
@@ -6,6 +6,19 @@
@@ -6,6 +6,19 @@ OLD_IFS=$IFS
PATH="@X_PATH@:$PATH"
OLD_IFS=$IFS

Expand All @@ -26,34 +26,34 @@

-if [ -f /etc/X11/Xresources ]; then
- sysresources=/etc/X11/Xresources
+if [ -f /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources ]; then
+ sysresources=/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources
+if [ -f /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources ]; then
+ sysresources=/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources
else
- sysresources=/usr/etc/X11/Xresources
+ sysresources=/usr/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources
+ sysresources=/usr/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xresources
fi

# merge in defaults
@@ -33,10 +46,10 @@ if [ -f "$sysresources" ]; then
@@ -33,10 +46,10 @@ fi
xrdb -nocpp -merge "$sysresources"
fi

-if [ -f /etc/X11/Xmodmap ]; then
- sysmodmap=/etc/X11/Xmodmap
+if [ -f /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap ]; then
+ sysmodmap=/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap
+if [ -f /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap ]; then
+ sysmodmap=/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap
else
- sysmodmap=/usr/etc/X11/Xmodmap
+ sysmodmap=/usr/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap
+ sysmodmap=/usr/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/Xmodmap
fi

XMODMAP=`gdmwhich xmodmap`
@@ -93,5 +106,15 @@ if [ "x$SETXKBMAP" != "x" ] ; then
@@ -93,5 +106,15 @@ fi
fi
fi
fi
+
+# /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/xenodm/GiveConsole, fbtab(5)
+# /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/xenodm/GiveConsole, fbtab(5)
+if [ -c /dev/dri/card0 ]; then
+ /usr/sbin/chown _gdm /dev/dri/card0
+fi
Expand Down
4 changes: 2 additions & 2 deletions x11/gdm/files/patch-data_PostSession.in
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
--- data/PostSession.in.orig 2022-01-12 14:15:56 UTC
--- data/PostSession.in.orig 2022-03-21 18:12:40 UTC
+++ data/PostSession.in
@@ -1,3 +1,11 @@
#!/bin/sh

+# /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/xenodm/TakeConsole, fbtab(5)
+# /usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/usr/local/etc/X11/xenodm/TakeConsole, fbtab(5)
+if [ -c /dev/dri/card0 ]; then
+ /usr/sbin/chown root /dev/dri/card0
+fi
Expand Down
Loading

0 comments on commit f3439a4

Please sign in to comment.