From cdaf889d407a01d64c4ca02a11b376457c68b028 Mon Sep 17 00:00:00 2001 From: deraadt <> Date: Sat, 25 Apr 2009 17:36:48 +0000 Subject: [PATCH] Provide users by default with XTerm*loginShell:true. This situation just is ridiculous; xdm is totally broken since it never starts anything which resembles a "login shell". As a result, no configuration is brought into a process context to give to future xterms or *sh shells and thus cause them to run their .profile or .kshrc or such a thing, to get futher configuration. Therefore people are left with a totally bland unconfigured Unix environment in their xterms, and don't know how to change this since .profile is ignored. This problem shows hundreds of thousands of google hits. xdm is fundamentally broken, but we must solve this also for the startx methods, too, and for people running csh. It is clear that .xsession is not a solution to this problem at all (that is, assuming the people who suggest such a thing really mean a .xsession file with the execute bit set). This now becomes the recommended way for new users to get out of this stupid situation; if someone does not like it they can change it or delete it. Few will. Just watch. ok kettenis guenther millert --- src/etc/Makefile | 6 +++++- src/etc/root/dot.Xdefaults | 1 + src/etc/skel/dot.Xdefaults | 1 + 3 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 src/etc/root/dot.Xdefaults create mode 100644 src/etc/skel/dot.Xdefaults diff --git a/src/etc/Makefile b/src/etc/Makefile index d06f4725..6915b750 100644 --- a/src/etc/Makefile +++ b/src/etc/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.273 2009/04/21 09:12:24 deraadt Exp $ +# $OpenBSD: Makefile,v 1.274 2009/04/25 17:36:46 deraadt Exp $ TZDIR= /usr/share/zoneinfo LOCALTIME= Canada/Mountain @@ -101,6 +101,8 @@ distribution-etc-root-var: distrib-dirs ${DESTDIR}/root/.login; \ ${INSTALL} -c -o root -g wheel -m 644 dot.profile \ ${DESTDIR}/root/.profile; \ + ${INSTALL} -c -o root -g wheel -m 644 dot.Xdefaults \ + ${DESTDIR}/root/.Xdefaults; \ rm -f ${DESTDIR}/.cshrc ${DESTDIR}/.profile; \ ${INSTALL} -c -o root -g wheel -m 644 dot.cshrc \ ${DESTDIR}/.cshrc; \ @@ -115,6 +117,8 @@ distribution-etc-root-var: distrib-dirs ${DESTDIR}/etc/skel/.mailrc; \ ${INSTALL} -c -o root -g wheel -m 644 dot.profile \ ${DESTDIR}/etc/skel/.profile; \ + ${INSTALL} -c -o root -g wheel -m 644 dot.Xdefaults \ + ${DESTDIR}/etc/skel/.Xdefaults; \ ${INSTALL} -c -o root -g wheel -m 600 /dev/null \ ${DESTDIR}/etc/skel/.ssh/authorized_keys cd kerberosV; \ diff --git a/src/etc/root/dot.Xdefaults b/src/etc/root/dot.Xdefaults new file mode 100644 index 00000000..68226e70 --- /dev/null +++ b/src/etc/root/dot.Xdefaults @@ -0,0 +1 @@ +XTerm*loginshell:true diff --git a/src/etc/skel/dot.Xdefaults b/src/etc/skel/dot.Xdefaults new file mode 100644 index 00000000..68226e70 --- /dev/null +++ b/src/etc/skel/dot.Xdefaults @@ -0,0 +1 @@ +XTerm*loginshell:true