[gentoo-commits] repo/gentoo:master commit in: x11-apps/xdm/files/, x11-apps/xdm/

2024-05-15 Thread Matt Turner
commit: b782e55f772db4a2c12f5313be54f3918c969991
Author: Matt Turner  gentoo  org>
AuthorDate: Wed May 15 18:25:12 2024 +
Commit: Matt Turner  gentoo  org>
CommitDate: Wed May 15 18:35:40 2024 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b782e55f

x11-apps/xdm: Drop old versions

Signed-off-by: Matt Turner  gentoo.org>

 x11-apps/xdm/Manifest   |  1 -
 x11-apps/xdm/files/xdm-1.1.14-c99.patch | 38 ---
 x11-apps/xdm/xdm-1.1.14-r1.ebuild   | 83 -
 3 files changed, 122 deletions(-)

diff --git a/x11-apps/xdm/Manifest b/x11-apps/xdm/Manifest
index 190263a75b7d..cd9a71326a41 100644
--- a/x11-apps/xdm/Manifest
+++ b/x11-apps/xdm/Manifest
@@ -1,2 +1 @@
-DIST xdm-1.1.14.tar.xz 419324 BLAKE2B 
e1c4f1db1af670171e80b7ab759f8e477c84997a873401eb27042590eebe457b38dc7bc998c42e954012ce06c1f4c216655a9c2809a22d88e372c9f7b57e0ff0
 SHA512 
8ed1d2c946916c24cb4b2de9326f65629c97e53b145312c9cb9c6e4308d8b47d67d3981319fbd4feac9b3ed436b9dfb24a1c905d37d7bcf07b49c18a68c7a6e4
 DIST xdm-1.1.16.tar.xz 420072 BLAKE2B 
1a970b99a0848b0bcb55870c1665281afc355685b4e08148cefd953456fbed5dc71a9a66fa670e80f07de3502615e3c2e81293e9476f04ce965d73be5365bd9e
 SHA512 
a7e0aca67b770b3939aee2c12feac3c0f5efa531ec4a6045ab8b53d9c35b701ab5533447feb39b7cbe0df74ff8483ee1637314b847b37a6c3f7e9c8fdf5e172d

diff --git a/x11-apps/xdm/files/xdm-1.1.14-c99.patch 
b/x11-apps/xdm/files/xdm-1.1.14-c99.patch
deleted file mode 100644
index a72d961e3f60..
--- a/x11-apps/xdm/files/xdm-1.1.14-c99.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-https://bugs.gentoo.org/919207
-https://gitlab.freedesktop.org/xorg/app/xdm/-/issues/15
-https://gitlab.freedesktop.org/xorg/app/xdm/-/merge_requests/18
-
-From bccb77746528134aa2e865ca4f44fd9424738b3f Mon Sep 17 00:00:00 2001
-From: Alan Coopersmith 
-Date: Tue, 5 Dec 2023 17:25:28 -0800
-Subject: [PATCH] Fix -Wincompatible-pointer-types warning from gcc (issue #15)
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-chooser.c:280:26: warning: passing argument 2 of ‘XawListChange’ from
- incompatible pointer type [-Wincompatible-pointer-types]
-  280 | XawListChange (list, newTable, size, 0, TRUE);
-  |  ^~~~
-  |  |
-  |  char **
-In file included from chooser.c:59:
-/usr/include/X11/Xaw/List.h:170:27: note: expected ‘const char **’ but
- argument is of type ‘char **’
-  170 |  _Xconst char   **list,
-
-Closes: #15
-Signed-off-by: Alan Coopersmith 
 a/chooser/chooser.c
-+++ b/chooser/chooser.c
-@@ -277,7 +277,7 @@ RebuildTable (int size)
-   newTable[i] = names->fullname;
-   qsort (newTable, size, sizeof (char *), HostnameCompare);
- }
--XawListChange (list, newTable, size, 0, TRUE);
-+XawListChange (list, (_Xconst char **) newTable, size, 0, TRUE);
- free (NameTable);
- NameTable = newTable;
- NameTableSize = size;
--- 
-GitLab

diff --git a/x11-apps/xdm/xdm-1.1.14-r1.ebuild 
b/x11-apps/xdm/xdm-1.1.14-r1.ebuild
deleted file mode 100644
index d33d52bc8907..
--- a/x11-apps/xdm/xdm-1.1.14-r1.ebuild
+++ /dev/null
@@ -1,83 +0,0 @@
-# Copyright 1999-2024 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-XORG_TARBALL_SUFFIX="xz"
-inherit xorg-3 pam systemd
-
-DEFAULTVT=vt7
-
-DESCRIPTION="X.Org xdm application"
-
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv 
~s390 sparc x86"
-IUSE="pam systemd truetype xinerama xpm"
-
-RDEPEND="
-   x11-apps/sessreg
-   x11-apps/xconsole
-   x11-apps/xinit
-   x11-apps/xrdb
-   x11-apps/xsm
-   x11-libs/libX11
-   x11-libs/libXau
-   x11-libs/libXaw
-   x11-libs/libXdmcp
-   x11-libs/libXext
-   x11-libs/libXmu
-   x11-libs/libXt
-   virtual/libcrypt:=
-   pam? ( sys-libs/pam )
-   systemd? ( >=sys-apps/systemd-209:= )
-   truetype? (
-   x11-libs/libXrender
-   x11-libs/libXft
-   )
-   xinerama? ( x11-libs/libXinerama )
-   xpm? ( x11-libs/libXpm )
-   elibc_glibc? ( dev-libs/libbsd )"
-DEPEND="${RDEPEND}
-   x11-base/xorg-proto"
-
-PATCHES=(
-   "${FILESDIR}"/${PN}-1.1.14-c99.patch
-)
-
-src_prepare() {
-   sed -i -e 's:^Alias=.*$:Alias=display-manager.service:' \
-   xdm.service.in || die
-
-   # Disable XDM-AUTHORIZATION-1 (bug #445662).
-   # it causes issue with libreoffice and SDL games (bug #306223).
-   sed -i -e '/authorize/a DisplayManager*authName:
MIT-MAGIC-COOKIE-1' \
-   config/xdm-config.in || die
-
-   xorg-3_src_prepare
-}
-
-src_configure() {
-   local XORG_CONFIGURE_OPTIONS=(
-   --enable-ipv6
-   $(use_with pam)
-   $(use_with systemd systemd-daemon)
-   $(use_with truetype xft)
- 

[gentoo-commits] repo/gentoo:master commit in: x11-apps/xdm/files/, x11-apps/xdm/

2023-12-09 Thread Sam James
commit: 6c4df370a29c7e5ceb675dc33abb4fbce398cab8
Author: Sam James  gentoo  org>
AuthorDate: Sat Dec  9 16:37:52 2023 +
Commit: Sam James  gentoo  org>
CommitDate: Sat Dec  9 18:06:00 2023 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6c4df370

x11-apps/xdm: fix modern C issue

Closes: https://bugs.gentoo.org/919207
Signed-off-by: Sam James  gentoo.org>

 x11-apps/xdm/files/xdm-1.1.14-c99.patch | 38 +++
 x11-apps/xdm/xdm-1.1.14-r1.ebuild   | 83 +
 2 files changed, 121 insertions(+)

diff --git a/x11-apps/xdm/files/xdm-1.1.14-c99.patch 
b/x11-apps/xdm/files/xdm-1.1.14-c99.patch
new file mode 100644
index ..a72d961e3f60
--- /dev/null
+++ b/x11-apps/xdm/files/xdm-1.1.14-c99.patch
@@ -0,0 +1,38 @@
+https://bugs.gentoo.org/919207
+https://gitlab.freedesktop.org/xorg/app/xdm/-/issues/15
+https://gitlab.freedesktop.org/xorg/app/xdm/-/merge_requests/18
+
+From bccb77746528134aa2e865ca4f44fd9424738b3f Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith 
+Date: Tue, 5 Dec 2023 17:25:28 -0800
+Subject: [PATCH] Fix -Wincompatible-pointer-types warning from gcc (issue #15)
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+chooser.c:280:26: warning: passing argument 2 of ‘XawListChange’ from
+ incompatible pointer type [-Wincompatible-pointer-types]
+  280 | XawListChange (list, newTable, size, 0, TRUE);
+  |  ^~~~
+  |  |
+  |  char **
+In file included from chooser.c:59:
+/usr/include/X11/Xaw/List.h:170:27: note: expected ‘const char **’ but
+ argument is of type ‘char **’
+  170 |  _Xconst char   **list,
+
+Closes: #15
+Signed-off-by: Alan Coopersmith 
+--- a/chooser/chooser.c
 b/chooser/chooser.c
+@@ -277,7 +277,7 @@ RebuildTable (int size)
+   newTable[i] = names->fullname;
+   qsort (newTable, size, sizeof (char *), HostnameCompare);
+ }
+-XawListChange (list, newTable, size, 0, TRUE);
++XawListChange (list, (_Xconst char **) newTable, size, 0, TRUE);
+ free (NameTable);
+ NameTable = newTable;
+ NameTableSize = size;
+-- 
+GitLab

diff --git a/x11-apps/xdm/xdm-1.1.14-r1.ebuild 
b/x11-apps/xdm/xdm-1.1.14-r1.ebuild
new file mode 100644
index ..05afdd6ad05a
--- /dev/null
+++ b/x11-apps/xdm/xdm-1.1.14-r1.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+XORG_TARBALL_SUFFIX="xz"
+inherit xorg-3 pam systemd
+
+DEFAULTVT=vt7
+
+DESCRIPTION="X.Org xdm application"
+
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv 
~s390 ~sparc ~x86"
+IUSE="pam systemd truetype xinerama xpm"
+
+RDEPEND="
+   x11-apps/sessreg
+   x11-apps/xconsole
+   x11-apps/xinit
+   x11-apps/xrdb
+   x11-apps/xsm
+   x11-libs/libX11
+   x11-libs/libXau
+   x11-libs/libXaw
+   x11-libs/libXdmcp
+   x11-libs/libXext
+   x11-libs/libXmu
+   x11-libs/libXt
+   virtual/libcrypt:=
+   pam? ( sys-libs/pam )
+   systemd? ( >=sys-apps/systemd-209:= )
+   truetype? (
+   x11-libs/libXrender
+   x11-libs/libXft
+   )
+   xinerama? ( x11-libs/libXinerama )
+   xpm? ( x11-libs/libXpm )
+   elibc_glibc? ( dev-libs/libbsd )"
+DEPEND="${RDEPEND}
+   x11-base/xorg-proto"
+
+PATCHES=(
+   "${FILESDIR}"/${PN}-1.1.14-c99.patch
+)
+
+src_prepare() {
+   sed -i -e 's:^Alias=.*$:Alias=display-manager.service:' \
+   xdm.service.in || die
+
+   # Disable XDM-AUTHORIZATION-1 (bug #445662).
+   # it causes issue with libreoffice and SDL games (bug #306223).
+   sed -i -e '/authorize/a DisplayManager*authName:
MIT-MAGIC-COOKIE-1' \
+   config/xdm-config.in || die
+
+   xorg-3_src_prepare
+}
+
+src_configure() {
+   local XORG_CONFIGURE_OPTIONS=(
+   --enable-ipv6
+   $(use_with pam)
+   $(use_with systemd systemd-daemon)
+   $(use_with truetype xft)
+   $(use_with xinerama)
+   $(use_enable xpm xpm-logos)
+   --with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
+   --with-default-vt=${DEFAULTVT}
+   --with-xdmconfigdir=/etc/X11/xdm
+   )
+   xorg-3_src_configure
+}
+
+src_install() {
+   xorg-3_src_install
+
+   exeinto /usr/$(get_libdir)/X11/xdm
+   doexe "${FILESDIR}"/Xsession
+
+   use pam && pamd_mimic system-local-login xdm auth account session
+
+   # Keep /var/lib/xdm. This is where authfiles are stored. See #286350.
+   keepdir /var/lib/xdm
+}



[gentoo-commits] repo/gentoo:master commit in: x11-apps/xdm/files/, x11-apps/xdm/

2019-05-03 Thread Matt Turner
commit: 8d1be7f65bc45ddfea7e75a2c645138b787e4179
Author: Matt Turner  gentoo  org>
AuthorDate: Fri May  3 23:21:31 2019 +
Commit: Matt Turner  gentoo  org>
CommitDate: Fri May  3 23:23:44 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8d1be7f6

x11-apps/xdm: Drop old versions

Signed-off-by: Matt Turner  gentoo.org>

 x11-apps/xdm/Manifest  |   1 -
 .../xdm/files/xdm-1.1.11-arc4random-include.patch  |  18 --
 x11-apps/xdm/files/xdm-1.1.11-cve-2013-2179.patch  |  41 
 .../files/xdm-1.1.11-setproctitle-include.patch|  37 
 x11-apps/xdm/files/xdm-consolekit.patch| 230 -
 x11-apps/xdm/metadata.xml  |   1 -
 x11-apps/xdm/xdm-1.1.11-r3.ebuild  |  77 ---
 7 files changed, 405 deletions(-)

diff --git a/x11-apps/xdm/Manifest b/x11-apps/xdm/Manifest
index ae11f03d02d..141eede7e33 100644
--- a/x11-apps/xdm/Manifest
+++ b/x11-apps/xdm/Manifest
@@ -1,2 +1 @@
-DIST xdm-1.1.11.tar.bz2 446612 BLAKE2B 
ce9bed568e036a882ecc56d75f7ce8646d14ae00c754d6e5542ea5b186c3ef1ce8499e2d70190b4fbc4b344e0c70fd36deab5aacc5f1f55501db709300aee520
 SHA512 
fe6f2b7817c0f7f07a1f5f497edcdfa15b93986fd87f314daa472dac8625327ef46ebbf40d27fe8d4a8a2f8d5af8a01c4438a29356740e0eb350f2bd0c7ec0d5
 DIST xdm-1.1.12.tar.bz2 512074 BLAKE2B 
a82d124f4b7ce3185d703fca3aade92e86094602aec5343566ba8c91c54b70cdedbaea2fa6fee330d7ed48d9138b04a998aa2dae06db2683bfcce6c7693edc82
 SHA512 
1a4be0a070ced5db8fda6fc74794c9f9ed0cb37fa440fda6a3a7652aff62dfc3d7ba68b9facf054671ebf0f4db2a0eec29d0aa3716e3407ccd5529bac3553bdb

diff --git a/x11-apps/xdm/files/xdm-1.1.11-arc4random-include.patch 
b/x11-apps/xdm/files/xdm-1.1.11-arc4random-include.patch
deleted file mode 100644
index db948094b75..000
--- a/x11-apps/xdm/files/xdm-1.1.11-arc4random-include.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-diff -ur a/xdm/genauth.c b/xdm/genauth.c
 a/xdm/genauth.c2011-09-25 09:35:47.0 +0200
-+++ b/xdm/genauth.c2014-01-06 16:28:09.664060603 +0100
-@@ -40,6 +40,14 @@
- 
- #include 
- 
-+#ifdef HAVE_ARC4RANDOM
-+# ifdef __linux__
-+#  include 
-+# else
-+#  include 
-+# endif
-+#endif
-+
- #include 
- #define Time_t time_t
- 

diff --git a/x11-apps/xdm/files/xdm-1.1.11-cve-2013-2179.patch 
b/x11-apps/xdm/files/xdm-1.1.11-cve-2013-2179.patch
deleted file mode 100644
index 34ae7ceb3cd..000
--- a/x11-apps/xdm/files/xdm-1.1.11-cve-2013-2179.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 8d1eb5c74413e4c9a21f689fc106949b121c0117 Mon Sep 17 00:00:00 2001
-From: mancha 
-Date: Wed, 22 May 2013 14:20:26 +
-Subject: Handle NULL returns from glibc 2.17+ crypt().
-
-Starting with glibc 2.17 (eglibc 2.17), crypt() fails with EINVAL
-(w/ NULL return) if the salt violates specifications. Additionally,
-on FIPS-140 enabled Linux systems, DES/MD5-encrypted passwords
-passed to crypt() fail with EPERM (w/ NULL return).
-
-If using glibc's crypt(), check return value to avoid a possible
-NULL pointer dereference.
-
-Reviewed-by: Matthieu Herrb 
-Signed-off-by: Alan Coopersmith 

-diff --git a/greeter/verify.c b/greeter/verify.c
-index db3cb7d..b009e2b 100644
 a/greeter/verify.c
-+++ b/greeter/verify.c
-@@ -329,6 +329,7 @@ Verify (struct display *d, struct greet_info *greet, 
struct verify_info *verify)
-   struct spwd *sp;
- #  endif
-   char*user_pass = NULL;
-+  char*crypted_pass = NULL;
- # endif
- # ifdef __OpenBSD__
-   char*s;
-@@ -464,7 +465,9 @@ Verify (struct display *d, struct greet_info *greet, 
struct verify_info *verify)
- #  if defined(ultrix) || defined(__ultrix__)
-   if (authenticate_user(p, greet->password, NULL) < 0)
- #  else
--  if (strcmp (crypt (greet->password, user_pass), user_pass))
-+  crypted_pass = crypt (greet->password, user_pass);
-+  if ((crypted_pass == NULL)
-+  || (strcmp (crypted_pass, user_pass)))
- #  endif
-   {
-   if(!greet->allow_null_passwd || strlen(p->pw_passwd) > 0) {
---
-cgit v0.9.0.2-2-gbebe

diff --git a/x11-apps/xdm/files/xdm-1.1.11-setproctitle-include.patch 
b/x11-apps/xdm/files/xdm-1.1.11-setproctitle-include.patch
deleted file mode 100644
index 0a3f32bbea0..000
--- a/x11-apps/xdm/files/xdm-1.1.11-setproctitle-include.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-diff -ur a/xdm/choose.c b/xdm/choose.c
 a/xdm/choose.c 2011-09-25 09:35:47.0 +0200
-+++ b/xdm/choose.c 2014-01-06 16:33:09.628065364 +0100
-@@ -54,6 +54,14 @@
- #  include   
- # endif
- 
-+# ifdef HAVE_SETPROCTITLE
-+#  ifdef __linux__
-+#   include 
-+#  else
-+#   include 
-+#  endif
-+# endif
-+
- # include 
- # define Time_t time_t
- 
-diff -ur a/xdm/session.c b/xdm/session.c
 a/xdm/session.c2011-09-25 09:35:47.0 +0200
-+++ b/xdm/session.c2014-01-06 16:40:57.508072789 +0100
-@@ -54,6 +54,15 @@
- # include 
- #endif
- 
-+# ifdef HAVE_SETPROCTITLE
-+#  include 
-+#  i

[gentoo-commits] repo/gentoo:master commit in: x11-apps/xdm/files/, x11-apps/xdm/

2019-03-02 Thread Matt Turner
commit: 9eab4843656a9d806f902602ccb19584f8863792
Author: Matt Turner  gentoo  org>
AuthorDate: Sun Mar  3 00:27:58 2019 +
Commit: Matt Turner  gentoo  org>
CommitDate: Sun Mar  3 02:09:37 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9eab4843

x11-apps/xdm: Version bump to 1.1.2

Various changes, addressing multiple bugs (in some cases partially):
- Depend on x11-apps/xsm (bug 329833)
- Drop IUSE=xdm-auth (bug 445662)
- Add IUSE=xinerama (bug 384371)
- Add IUSE=truetype (bug 608840)
- Add IUSE=xpm
- Add IUSE=systemd
- Port to EAPI=7 and xorg-3.eclass

Bug: https://bugs.gentoo.org/329833
Bug: https://bugs.gentoo.org/445662
Closes: https://bugs.gentoo.org/384371
Closes: https://bugs.gentoo.org/608840
Signed-off-by: Matt Turner  gentoo.org>

 x11-apps/xdm/Manifest  |   1 +
 x11-apps/xdm/files/xdm-1.1.12-consolekit.patch | 269 +
 .../files/xdm-1.1.12-make-xinerama-optional.patch  |  34 +++
 x11-apps/xdm/xdm-1.1.12.ebuild |  84 +++
 4 files changed, 388 insertions(+)

diff --git a/x11-apps/xdm/Manifest b/x11-apps/xdm/Manifest
index 0911b632ce9..ae11f03d02d 100644
--- a/x11-apps/xdm/Manifest
+++ b/x11-apps/xdm/Manifest
@@ -1 +1,2 @@
 DIST xdm-1.1.11.tar.bz2 446612 BLAKE2B 
ce9bed568e036a882ecc56d75f7ce8646d14ae00c754d6e5542ea5b186c3ef1ce8499e2d70190b4fbc4b344e0c70fd36deab5aacc5f1f55501db709300aee520
 SHA512 
fe6f2b7817c0f7f07a1f5f497edcdfa15b93986fd87f314daa472dac8625327ef46ebbf40d27fe8d4a8a2f8d5af8a01c4438a29356740e0eb350f2bd0c7ec0d5
+DIST xdm-1.1.12.tar.bz2 512074 BLAKE2B 
a82d124f4b7ce3185d703fca3aade92e86094602aec5343566ba8c91c54b70cdedbaea2fa6fee330d7ed48d9138b04a998aa2dae06db2683bfcce6c7693edc82
 SHA512 
1a4be0a070ced5db8fda6fc74794c9f9ed0cb37fa440fda6a3a7652aff62dfc3d7ba68b9facf054671ebf0f4db2a0eec29d0aa3716e3407ccd5529bac3553bdb

diff --git a/x11-apps/xdm/files/xdm-1.1.12-consolekit.patch 
b/x11-apps/xdm/files/xdm-1.1.12-consolekit.patch
new file mode 100644
index 000..232d10d94db
--- /dev/null
+++ b/x11-apps/xdm/files/xdm-1.1.12-consolekit.patch
@@ -0,0 +1,269 @@
+http://bugs.gentoo.org/360987
+http://projects.archlinux.org/svntogit/packages.git/plain/trunk/xdm-consolekit.patch?h=packages/xorg-xdm
+http://lists.x.org/archives/xorg-devel/2011-February/019615.html
+http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=615020
+---
+ configure.ac   |  20 --
+ include/dm.h   |   3 ++
+ man/xdm.man|   6 +++
+ xdm/resource.c |  13 ++-
+ xdm/session.c  | 102 +
+ 5 files changed, 140 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index d110809..db973f7 100644
+--- a/configure.ac
 b/configure.ac
+@@ -168,15 +168,15 @@ AS_IF([test "x$with_systemdsystemunitdir" != "xno"], [
+ AM_CONDITIONAL(HAVE_SYSTEMD, [test "x$with_systemdsystemunitdir" != "xno"])
+ 
+ # Check whether to enable systemd startup notification.
+-# This requires libsystemd-daemon.
++# This requires libsystemd.
+ AC_ARG_WITH([systemd-daemon], AS_HELP_STRING([--with-systemd-daemon],
+   [Add support for systemd startup notification (default is 
autodetected)]),
+   [USE_SYSTEMD_DAEMON=$withval], [USE_SYSTEMD_DAEMON=auto])
+ AS_IF([test "x$USE_SYSTEMD_DAEMON" != "xno"], [
+-PKG_CHECK_MODULES([SYSTEMD_DAEMON], [libsystemd-daemon],
++PKG_CHECK_MODULES([SYSTEMD_DAEMON], [libsystemd],
+   [AC_DEFINE(USE_SYSTEMD_DAEMON,1,[Use systemd startup notification])],
+   [AS_IF([test "x$USE_SYSTEMD_DAEMON" = "xyes"],
+-  [AC_MSG_ERROR([systemd startup notification support requested, but 
libsystemd-daemon not found.])]
++  [AC_MSG_ERROR([systemd startup notification support requested, but 
libsystemd not found.])]
+   )]
+ )
+ ])
+@@ -395,6 +395,20 @@ PKG_CHECK_MODULES(DMCP, xdmcp)
+ PKG_CHECK_MODULES(XLIB, x11)
+ PKG_CHECK_MODULES(AUTH, xau)
+ 
++# ConsoleKit support
++AC_ARG_WITH(consolekit, AC_HELP_STRING([--with-consolekit], [Use ConsoleKit]),
++  [USE_CONSOLEKIT=$withval], [USE_CONSOLEKIT=yes])
++if test x"$USE_CONSOLEKIT" != xno; then
++  PKG_CHECK_MODULES(CK_CONNECTOR, ck-connector,
++  [USE_CONSOLEKIT=yes], [USE_CONSOLEKIT=no])
++  if test x"$USE_CONSOLEKIT" = xyes; then
++  AC_DEFINE([USE_CONSOLEKIT], 1, [Define to 1 to use ConsoleKit])
++  XDM_CFLAGS="$XDM_CFLAGS $CK_CONNECTOR_CFLAGS -DUSE_CONSOLEKIT"
++  XDM_LIBS="$XDM_LIBS $CK_CONNECTOR_LIBS"
++  fi
++fi
++dnl AM_CONDITIONAL(USE_CONSOLEKIT, test$USE_CONSOLEKIT = xyes)
++
+ #
+ # Greeter
+ #
+diff --git a/include/dm.h b/include/dm.h
+index 9116d6f..27fdd71 100644
+--- a/include/dm.h
 b/include/dm.h
+@@ -327,6 +327,9 @@ extern char*randomFile;
+ extern char   *prngdSocket;
+ extern intprngdPort;
+ # endif
++#ifdef USE_CONSOLEKIT
++extern intuse_consolekit;
++#endif
+ 
+ extern char   *greeterLib;
+ extern