With the advent of the K Desktop Environment's kdm, Gnome's gdm, and the associated out-of-the-box, ready-to-use setups, configuration of xdm seems to have become something of a lost art. Nevertheless, for small machines like 68K Macintoshes, xdm and a vanilla window manager like twm, icewm or fvwm v1 do still provide the most efficient work environment.
The canonical source of knowledge about proper care and feeding of the X Display Manager xdm(1) is the manpage. Unfortunately, the NetBSD web manpages do not include X11 manpages; a copy of the NetBSD 3.0 xdm manpage is here. Yes, it's that long.
Obviously, it will help a lot if you can find your way through a POSIX shell script, and have a rough idea of X11 ressources. Apart from the occasional helpful web page (for a few links see below), searching old usenet postings in the comp.windows.x hierarchy with groups.google.com could be a good idea.
But since a proper Unix manpage is terse and a bit dry, I decided to put up the commented xdm configuration of my Macintosh Quadra 700 to give an example of what can be tweaked.
Note: Before you replace your xdm setup in part with the files provided here, make sure you have a backup of the original files.
Older NetBSD systems have the xdm configuration files under /usr/X11R6/lib/X11/xdm/. On newer systems, the X11 setup has been moved to /etc/X11/. With something like
xdm=YES xdm_flags="-config /etc/X11/xdm/xdm-config"
in /etc/rc.conf, you can point xdm to a non-default config file which then holds modified paths to all of xdm's setup.
If you want to work with the example, it is probably easiest to just download the tarball.
So, what is here?
> ls -la xdm-scripts total 204 drwxr-xr-x 3 hauke users 512 May 28 19:25 . drwxr-xr-x 4 hauke users 512 May 28 19:22 .. drwxr-xr-x 2 hauke users 512 May 28 19:24 CVS -rw-r--r-- 1 hauke users 528 May 28 19:24 Makefile -rw-r--r-- 1 hauke users 64268 May 28 19:22 NetBSD.xpm -rw-r--r-- 1 hauke users 60270 May 28 19:22 NetBSDbw.xpm -rw-r--r-- 1 hauke users 63567 May 28 19:22 NetBSDinv.xpm -rw-r--r-- 1 hauke users 4671 May 28 19:24 Xresources -rw-r--r-- 1 hauke users 3391 May 28 19:24 Xresources.global -rw-r--r-- 1 hauke users 3033 May 28 19:24 Xsession.sh -rw-r--r-- 1 hauke users 226 May 28 19:24 Xsetup_0.sh -rw-r--r-- 1 hauke users 1301 May 28 19:24 xdm-config >
The enclosed BSD Makefile takes care of installing all the bits in the proper places with the proper permissions.
The X11 pixmap files NetBSD.xpm, NetBSDbw.xpm, NetBSDinv.xpm replace the generic X11 pixmaps in the xdm greeter for older NetBSD releases. Unlike at least some versions of the original NetBSD pixmaps, they are properly set up for eight bit displays. A screenshot of the modified login screen is here - it was made with xwd(1).
The xdm Xresources file gets processed by cpp(1), the C preprocessor, and contains standard X11 resources. It is modeled after Olaf Seibert's post on the NetBSD current-users list. It reverts the pseudo-3D look of the current XFree86 xdm to the older flat look which is more appropriate to the limited depth, greyscale display of 68k Macs.
Xresources.global is an X11 resource file with application-specific settings. If you want to try it out, copy the file manually to /etc/X11/Xresources; it is sourced by the Xsession.sh script.
Xsession.sh (installed chmod +x as Xsession) is a shell script that xdm executes on behalf of the user who has just logged in successfully. It sets up the X11 session, and finally starts up a window manager.
The detailed sequence of events:
Xsetup_0.sh (installed chmod +x as Xsetup_0) is run as root for per-display pre-login setup. In addition to start xconsole, we enable access to the display from localhost. You could also start xscreensaver here.
xdm-config is the xdm master config file that has the paths to all the other files that xdm uses. The example file sets a few things explicitely to take care of older installations where the xdm default paths point to /usr/X11R6/lib/X11/xdm/.
TBD
/etc/X0.hosts and /etc/hosts.equiv
TBD