* xdosemu & the _X_... variables in dosemu.conf
@ 2002-04-26 21:41 Hartmut Figge
2002-04-27 10:06 ` Grigory Batalov
0 siblings, 1 reply; 4+ messages in thread
From: Hartmut Figge @ 2002-04-26 21:41 UTC (permalink / raw)
To: linux-msdos; +Cc: Herbert Xu
Greetings,
the following problem can eventually be solved by the developers of
dosemu or perhaps be circumvented by others. I have Cc'ed the dosemu
maintainer of my distro. Possible followups should go to linux-msdos.
The problem:
the variables in dosemu.conf beginning with _X_ will not be evaluated,
if xdosemu is started from the menu of an windowmanger _and_ X was
started with 'startx' from the console.
Proof:
in dosemu.conf set _X_title = "strange". If not present, add a menu-item
to your windowmanger to start xdosemu. Start X with startx, _not_ with
xdm or similar.
If you now start xdosemu from an xterm, you will see the title 'strange'
at the top of the xdosemu window as expected, but if you start xdosemu
from the menu you will not.
Reason:
in $DOSEMU_LIB_DIR/global.conf are the lines
if ($DOSEMU_STDIN_IS_CONSOLE eq "1")
$BEING_ON = "console"
else
and DOSEMU_STDIN_IS_CONSOLE was set by evaluating the output of 'who am
i', which contains the terminal. And this terminal will be tty?, if you
have started X by 'startx', unless you start xdosemu from an xterm.
$BEING_ON = "console" will bypass the evaluating of the _X_... variables
in dosemu.conf.
For me, i have a very ugly workaround. I have inserted the lines
if ($SURELY_X)
$DOSEMU_STDIN_IS_CONSOLE=(0)
endif
just before the earlier mentioned lines, start xdosemu from the menu of
the windowmanager with the command 'xdosemu.fake', where 'xdosemu.fake'
is a shell-script with the lines
#!/bin/sh
export SURELY_X=1
xdosemu
unset SURELY_X
cu
--
hafi
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: xdosemu & the _X_... variables in dosemu.conf
2002-04-26 21:41 xdosemu & the _X_... variables in dosemu.conf Hartmut Figge
@ 2002-04-27 10:06 ` Grigory Batalov
2002-06-21 15:56 ` witek
0 siblings, 1 reply; 4+ messages in thread
From: Grigory Batalov @ 2002-04-27 10:06 UTC (permalink / raw)
To: linux-msdos
On Fri, 26 Apr 2002 23:41:32 +0200
"Hartmut Figge" <hfigge@uni.de> wrote:
> For me, i have a very ugly workaround. I have inserted the lines
>
> if ($SURELY_X)
> $DOSEMU_STDIN_IS_CONSOLE=(0)
> endif
>
> just before the earlier mentioned lines, start xdosemu from the menu of
> the windowmanager with the command 'xdosemu.fake', where 'xdosemu.fake'
> is a shell-script with the lines
>
> #!/bin/sh
> export SURELY_X=1
> xdosemu
> unset SURELY_X
It's no bad =), my patch looks like this:
------
diff -ruN dosemu-1.1.2.orig/src/base/init/config.c dosemu-1.1.2/src/base/init/config.c
--- dosemu-1.1.2.orig/src/base/init/config.c Mon Mar 18 23:26:44 2002
+++ dosemu-1.1.2/src/base/init/config.c Tue Mar 19 00:54:20 2002
@@ -611,6 +611,10 @@
}
buf[j] = 0;
setenv("DOSEMU_OPTIONS", buf, 1);
+ if (usedoptions['X'])
+ { strcpy(buf, "0");
+ setenv("DOSEMU_STDIN_IS_CONSOLE",buf,1);
+ }
return;
}
uname(&unames);
------
--
Grigory Batalov.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: xdosemu & the _X_... variables in dosemu.conf
2002-04-27 10:06 ` Grigory Batalov
@ 2002-06-21 15:56 ` witek
2002-06-22 13:44 ` pesarif
0 siblings, 1 reply; 4+ messages in thread
From: witek @ 2002-06-21 15:56 UTC (permalink / raw)
To: linux-msdos
[-- Attachment #1: Type: text/plain, Size: 1215 bytes --]
On Sat, Apr 27, 2002 at 02:06:51PM +0400, Grigory Batalov wrote:
> On Fri, 26 Apr 2002 23:41:32 +0200
> "Hartmut Figge" <hfigge@uni.de> wrote:
>
> > For me, i have a very ugly workaround. I have inserted the lines
> >
> > if ($SURELY_X)
> > $DOSEMU_STDIN_IS_CONSOLE=(0)
> > endif
> >
> > just before the earlier mentioned lines, start xdosemu from the menu of
> > the windowmanager with the command 'xdosemu.fake', where 'xdosemu.fake'
> > is a shell-script with the lines
> >
> > #!/bin/sh
> > export SURELY_X=1
> > xdosemu
> > unset SURELY_X
>
> It's no bad =), my patch looks like this:
> ------
> diff -ruN dosemu-1.1.2.orig/src/base/init/config.c dosemu-1.1.2/src/base/init/config.c
> --- dosemu-1.1.2.orig/src/base/init/config.c Mon Mar 18 23:26:44 2002
> +++ dosemu-1.1.2/src/base/init/config.c Tue Mar 19 00:54:20 2002
> @@ -611,6 +611,10 @@
> }
> buf[j] = 0;
> setenv("DOSEMU_OPTIONS", buf, 1);
> + if (usedoptions['X'])
> + { strcpy(buf, "0");
> + setenv("DOSEMU_STDIN_IS_CONSOLE",buf,1);
> + }
> return;
> }
> uname(&unames);
Here is my proposal, which hopefully solve the problem.
--
Witold Filipczyk <witekfl@poczta.onet.pl>
[-- Attachment #2: dosemu-1.1-global.conf.patch --]
[-- Type: text/plain, Size: 658 bytes --]
--- dosemu-1.1.3/etc/global.conf.orig Fri Jun 21 12:31:18 2002
+++ dosemu-1.1.3/etc/global.conf Fri Jun 21 13:10:10 2002
@@ -245,9 +245,6 @@
else
$BEING_ON = ""
endif
- if ( (strchr($DOSEMU_OPTIONS,"X") >=0) && ($DISPLAY ne "") )
- $USING_X = (1)
- endif
if (strstr("xterm dtterm", $TERM) >= 0)
$BEING_ON = $BEING_ON, "_xterm"
else
@@ -261,6 +258,12 @@
endif
endif
+ if ( (strchr($DOSEMU_OPTIONS,"X") >=0) && ($DISPLAY ne "") )
+ $USING_X = (1)
+ endif
+ if (($BEING_ON eq "console") && ($USING_X))
+ $BEING_ON = ""
+ endif
warn "dosemu running on ", $BEING_ON;
$xxx = $_term_char_set
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: xdosemu & the _X_... variables in dosemu.conf
2002-06-21 15:56 ` witek
@ 2002-06-22 13:44 ` pesarif
0 siblings, 0 replies; 4+ messages in thread
From: pesarif @ 2002-06-22 13:44 UTC (permalink / raw)
To: witek, linux-msdos
On Sat, 22 Jun 2002 01:56, witek@lte5000.fixsoftware.pl wrote:
> Here is my proposal, which hopefully solve the problem.
your patch dosemu-1.1-global.conf.patch solves my problem of the X_title not
being processed if dosemu.bin -X is run from the cmd line (ver 1.1.3.2). the
patch that came with 1.1.3.2 did not fix my problem but your patch did!
thanx
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-06-22 13:44 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-26 21:41 xdosemu & the _X_... variables in dosemu.conf Hartmut Figge
2002-04-27 10:06 ` Grigory Batalov
2002-06-21 15:56 ` witek
2002-06-22 13:44 ` pesarif
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox