Description: Remove all traces of /usr/bin/X11, /usr/ucb and /usr/X11R6
 and update the man page and some defaults wrt. to these and other
 non-debianish paths and defaults, e.g. replace xterm with
 x-terminal-emulator.
Bug-Debian: https://bugs.debian.org/821889
Author: Axel Beckert <abe@debian.org>

Index: wdm/src/wdm/resource.c
===================================================================
--- wdm.orig/src/wdm/resource.c	2016-04-20 21:49:42.000000000 +0200
+++ wdm/src/wdm/resource.c	2016-04-20 21:49:42.000000000 +0200
@@ -107,25 +107,25 @@
  */
 #ifndef __EMX__
 #ifndef DEF_SERVER_LINE 
-#define DEF_SERVER_LINE ":0 local /usr/bin/X11/X :0"
+#define DEF_SERVER_LINE ":0 local /usr/bin/X :0"
 #endif
 #ifndef XRDB_PROGRAM
-#define XRDB_PROGRAM "/usr/bin/X11/xrdb"
+#define XRDB_PROGRAM "/usr/bin/xrdb"
 #endif
 #ifndef DEF_SESSION
-#define DEF_SESSION "/usr/bin/X11/xterm -ls"
+#define DEF_SESSION "/usr/bin/xterm -ls"
 #endif
 #ifndef DEF_USER_PATH
-#define DEF_USER_PATH ":/bin:/usr/bin:/usr/bin/X11:/usr/ucb"
+#define DEF_USER_PATH ":/bin:/usr/bin"
 #endif
 #ifndef DEF_SYSTEM_PATH
-#define DEF_SYSTEM_PATH "/etc:/bin:/usr/bin:/usr/bin/X11:/usr/ucb"
+#define DEF_SYSTEM_PATH "/etc:/bin:/usr/bin"
 #endif
 #ifndef DEF_SYSTEM_SHELL
 #define DEF_SYSTEM_SHELL "/bin/sh"
 #endif
 #ifndef DEF_FAILSAFE_CLIENT
-#define DEF_FAILSAFE_CLIENT "/usr/bin/X11/xterm"
+#define DEF_FAILSAFE_CLIENT "/usr/bin/x-terminal-emulator"
 #endif
 #ifndef DEF_XDM_CONFIG
 #define DEF_XDM_CONFIG "/usr/lib/X11/xdm/xdm-config"
Index: wdm/doc/wdm.man.in
===================================================================
--- wdm.orig/doc/wdm.man.in	2016-04-20 21:49:42.000000000 +0200
+++ wdm/doc/wdm.man.in	2016-04-20 21:49:42.000000000 +0200
@@ -244,12 +244,12 @@
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.chooser\fP"
 Specifies the program run to offer a host menu for Indirect queries
 redirected to the special host name CHOOSER.
-\fI/usr/X11R6/bin/chooser\fP is the default.
+\fI/usr/lib/X11/xdm/chooser\fP is the default.
 See the sections \fBXDMCP Access Control\fP and \fBChooser\fP.
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.xrdb\fP"
 Specifies the program used to load the resources.  By default,
 .I wdm
-uses \fI/usr/X11R6/bin/xrdb\fP.
+uses \fI/usr/bin/xrdb\fP.
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.cpp\fP"
 This specifies the name of the C preprocessor which is used by \fIxrdb\fP.
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.setup\fP"
@@ -267,7 +267,7 @@
 See the section \fBStartup Program.\fP
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.session\fP"
 This specifies the session to be executed (not running as root).
-By default, \fI/usr/X11R6/bin/xterm\fP is
+By default, \fI/usr/bin/x-terminal-emulator\fP is
 run.  The conventional name is \fIXsession\fP.
 See the section
 .B "Session Program."
@@ -330,7 +330,7 @@
 be a colon separated list of directories; see
 .IR sh (1)
 for a full description.
-``:/bin:/usr/bin:/usr/X11R6/bin:/usr/ucb''
+``:/bin:/usr/bin:/usr/games''
 is a common setting.
 The default value can be specified at build time in the X system
 configuration file with DefaultUserPath.
@@ -339,7 +339,7 @@
 sets the PATH environment variable for the startup and reset scripts to the
 value of this resource.  The default for this resource is specified
 at build time by the DefaultSystemPath entry in the system configuration file;
-``/etc:/bin:/usr/bin:/usr/X11R6/bin:/usr/ucb'' is a common choice.
+``/etc:/bin:/usr/bin'' is a common choice.
 Note the absence of ``.'' from this entry.  This is a good practice to
 follow for root; it avoids many common Trojan Horse system penetration
 schemes.
@@ -353,7 +353,7 @@
 will fall back to this program.  This program is executed with no
 arguments, but executes using the same environment variables as
 the session would have had (see the section \fBSession Program\fP).
-By default, \fI/usr/X11R6/bin/xterm\fP is used.
+By default, \fI/usr/bin/x-terminal-emulator\fP is used.
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.grabServer\fP"
 .IP "\fBDisplayManager.\fP\fIDISPLAY\fP\fB.grabTimeout\fP"
 To improve security,
@@ -483,12 +483,12 @@
 
 .ta .5i 4i
 
-	DisplayManager.servers:	/usr/X11R6/lib/X11/xdm/Xservers
-	DisplayManager.errorLogFile:	/usr/X11R6/lib/X11/xdm/xdm-errors
-	DisplayManager*resources:	/usr/X11R6/lib/X11/xdm/Xresources
-	DisplayManager*startup:	/usr/X11R6/lib/X11/xdm/Xstartup
-	DisplayManager*session:	/usr/X11R6/lib/X11/xdm/Xsession
-	DisplayManager.pidFile:	/usr/X11R6/lib/X11/xdm/xdm-pid
+	DisplayManager.servers:	/usr/lib/X11/xdm/Xservers
+	DisplayManager.errorLogFile:	/usr/lib/X11/xdm/xdm-errors
+	DisplayManager*resources:	/usr/lib/X11/xdm/Xresources
+	DisplayManager*startup:	/usr/lib/X11/xdm/Xstartup
+	DisplayManager*session:	/usr/lib/X11/xdm/Xsession
+	DisplayManager.pidFile:	/usr/lib/X11/xdm/xdm-pid
 	DisplayManager._0.authorize:	true
 	DisplayManager*authorize:	false
 
@@ -634,7 +634,7 @@
 
 \&	#!/bin/sh
 \&	# Xsetup_0 \- setup script for one workstation
-	xcmsdb < /usr/X11R6/lib/monitors/alex.0
+	xcmsdb < /usr/local/lib/monitors/alex.0
 	xconsole\0\-geometry\0480x130\-0\-0\0\-notify\0\-verbose\0\-exitOnFail &
 
 .fi
Index: wdm/configs/Xclients.in
===================================================================
--- wdm.orig/configs/Xclients.in	2016-04-20 21:49:42.000000000 +0200
+++ wdm/configs/Xclients.in	2016-04-20 21:49:42.000000000 +0200
@@ -202,5 +202,5 @@
 
 # No other window or session manager found.
 # Use twm as a last resort.
-xterm &
+x-terminal-emulator &
 exec twm
