Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* Some patches for enlightenment on Alpha/Tru64
@ 1999-12-10  5:00 Bob Arendt
  0 siblings, 0 replies; only message in thread
From: Bob Arendt @ 1999-12-10  5:00 UTC (permalink / raw)


I've been built enlightenment 0.16.3 on an Alpha under Tru64 4.0e.
Ran into two problems that I have patches for, and a third problem
with a workaround.

BTW - enlightenment's great - impresses the hell out people I give
demos to.  I've set aside the native Tru64 CDE.

Patch 1:-------------------------
Symptom: eesh runs.  On exit, the parent shell/xterm exit as well.
What's happening:  eesh sets O_NONBLOCK on stdin.  Under Tru64,
this can permanently affect parent's pty.  The parent (interactive)
shell
barfs.  The patch (context diff on 9-Dec-99 CVS source) restores the
state on exit.  Tested on Tru64 4.0e+patchkit2 and Redhat 6.0 i386.
I'd recommend this for addition to the source.

~/CVS/enlightenment[15] diff -c e/eesh/main.c{_orig,}
*** e/eesh/main.c_orig  Fri Dec 10 03:17:35 1999
--- e/eesh/main.c       Fri Dec 10 03:19:56 1999
***************
*** 30,35 ****
--- 30,40 ----
  
  extern char         waitonly;
  
+ static int stdin_state;
+ void restore_stdin_state(void) {
+    fcntl(0, F_SETFL, stdin_state);
+ }
+ 
  int
  main(int argc, char **argv)
  {
***************
*** 112,117 ****
--- 117,124 ----
  
     XSync(disp, False);
     j = 0;
+    stdin_state = fcntl(0, F_GETFL, 0);
+    atexit( restore_stdin_state );
     fcntl(0, F_SETFL, O_NONBLOCK);
     for (;;)
       {


Patch 2:-------------------------
Symptom: Menu items using "exec" don't work (most of them).  On rare
occasions it succeeds.  Enlightenment pops up the dialog containing
the phrase "I suggest you read the manual page for that shell and 
read up how to change or add to your execution path".

What's happening:  Looks like a weird race condition in actions.c,
not an enlightenment bug.  The ExecApplication call does a popen()
and the first fread() on the pipe "succeeds" in reading 0 bytes,
as if it were non-blocking (non-blocking is not set).  Either
a 40msec pause or secondary fread() will succeed.  Don't know
why - closed source OS.  I'm submitting a bug report to Compaq/Dec,
but here's a workaround patch that seems to work.
Not recommended for CVS :-), though the patch is also against
current CVS source.

~/CVS/enlightenment[16] diff -c e/src/actions.c{_orig,}
*** e/src/actions.c_orig        Fri Dec 10 03:42:26 1999
--- e/src/actions.c     Fri Dec 10 03:49:38 1999
***************
*** 784,790 ****
     f = popen(exe, "r");
     if (f)
       {
!       fread(s, 1, FILEPATH_LEN_MAX, f);
        s[FILEPATH_LEN_MAX - 1] = 0;
        l = strlen(s);
        s[l - 1] = 0;
--- 784,792 ----
     f = popen(exe, "r");
     if (f)
       {
!       int n = fread(s, 1, FILEPATH_LEN_MAX, f);
!       if (n==0) /** RDA: weird Tru64 bug **/
!          fread(s, 1, FILEPATH_LEN_MAX, f);
        s[FILEPATH_LEN_MAX - 1] = 0;
        l = strlen(s);
        s[l - 1] = 0;


Problem 3: ------------------------
Problem: Xdec (Tru64 Xserver 4.0e) crashes as enlightenment starts
What's happening:  Turn off shared pixmaps in .imrc, and
everything's fine.  When the Xserver crashes, the Xdec core dump
indicates that it's trying to free shared pixmaps.  Oddly
enough the MIT-SHM works, but shared pixmaps don't.
Have to put up with annoying prompts at startup advising me to
enable shared-pixmaps, though.  Could be a peculiar to my rig,
a side-effect of multihead + lots of visuals.

If anyone else using Compaq/Dec Tru64 (formerly OSF1) has some
experience with this, please contact me by email at
rdarendt@cwcom.net
I'm interested non-problems as well (Someone running
enlightenment on Tru64 with pixmaps enabled successfully ?).

Cheers,
-Bob Arendt



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1999-12-10  5:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-12-10  5:00 Some patches for enlightenment on Alpha/Tru64 Bob Arendt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox