This is the mail archive of the cygwin-xfree mailing list for the Cygwin XFree86 project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Proposed patch to system.XWinrc

Ken Brown wrote:
I recommend that the xorg-server maintainers consider the following patch to system.XWinrc:

--- system.XWinrc.orig  2009-02-22 12:27:28.000000000 -0500
+++ system.XWinrc       2009-06-09 11:57:50.328125000 -0400
@@ -79,8 +79,8 @@

 // Make some menus...
 menu apps {
-       xterm   exec    "xterm"
-       "Emacs"         exec    "emacs"
+       xterm   exec    "xterm -ls"

I agree. In fact I think perhaps "xterm -ls -sb"

+       emacs   exec    "bash -l -c /usr/bin/emacs"
        notepad exec    notepad
        xload   exec    "xload -display %display%"  # Comment

The most important part of this is changing the way emacs is called; the original version didn't work at all for me (i.e., emacs didn't start). This might be related to the fact that I've installed the emacs-23 packages, which use the alternatives system:

/usr/bin/emacs -> /etc/alternatives/emacs
/etc/alternatives/emacs -> /usr/bin/emacs-X11.exe

The command lines for menu items are just supplied to execl('/bin/sh -c ...') after a fork, so it should have no problem following symlinks, and a bare "emacs" works for me (I tested 23.0.92 under Cygwin 1.7)

If you start your X server from a shell, and then try to start emacs from the tray menu, you may get something written indicating why the emacs could not be started. (You need CYGWIN=tty to see the output from Xwin)

It's true the error logging if the command fails is rather deficient, although if something goes wrong in the shell after we've exec'ed it's somewhat out of our control, although I suppose we could arrange for stdout/stderr to be connected to /var/log/Xwin.*.log, rather than the terminal.

Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]