From owner-freebsd-gnome@freebsd.org Sun Jan 29 15:38:39 2017 Return-Path: Delivered-To: freebsd-gnome@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3F520CC773C for ; Sun, 29 Jan 2017 15:38:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 290091CA2 for ; Sun, 29 Jan 2017 15:38:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id 25609CC773B; Sun, 29 Jan 2017 15:38:39 +0000 (UTC) Delivered-To: gnome@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 25052CC7739 for ; Sun, 29 Jan 2017 15:38:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EEC671CA0 for ; Sun, 29 Jan 2017 15:38:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id v0TFccPQ096420 for ; Sun, 29 Jan 2017 15:38:38 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: gnome@FreeBSD.org Subject: [Bug 202269] [patch] sysutils/consolekit update to 1.0.0 Date: Sun, 29 Jan 2017 15:38:38 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: patch X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: jesper@schmitz.computer X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: gnome@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: attachments.created Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-gnome@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: GNOME for FreeBSD -- porting and maintaining List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 29 Jan 2017 15:38:39 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D202269 --- Comment #8 from Jesper Schmitz Mouridsen --- Created attachment 179399 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D179399&action= =3Dedit Update to consolekit 1.0.2 with active sessions working. This is another approach. I have narrowed the problem down. On Linux the X process' control tty is the same as Xfree86_VT (e.g the display device). On FreeBSD it is the invoking tty. e.g startx on /dev/ttyv1 the Xorg procees' = tt is ttyv1 even though Xfree86_VT is vt9 Inspired by http://unix.stackexchange.com/questions/32884/which-virtual-terminal-is-a-g= iven-x-process-running-on I use libprocstat to read the actual display device from pid. e.g no need to only use the root window property XFree86_VT as in my previous patch. This needs the ck-get-x11-display-device to be setuid root. The Makefile reflects/sets this. Another problem was that the active tty is returned as full path and display-deivce was only ttyvX. I have prefixed display-device with "/dev/" ck-sysdeps-freebsd.c @@ -128,7 +128,7 @@ ck_process_stat_get_tty (CkProcessStat *stat) { g_return_val_if_fail (stat !=3D NULL, NULL); - return g_strdup (stat->tty_text); + return g_strdup_printf("/dev/%s",stat->tty_text); } Furhermore I have reverted the use of consolectl as it does not work on 11-RELEASE. I have not tested on 10. --=20 You are receiving this mail because: You are the assignee for the bug.=