[comp.unix.aux] Minor problems with ELM and A/UX

alexis@panix.uucp (Alexis Rosen) (04/11/91)

I've built the latest version of ELM for A/UX recently and it seems to
function quite well. But there are a few little problems that I'd like to
fix up.

1) Often, when I ues job control to go off and do something, when I come back
to ELM it no longer acts as soon as I type a character- it waits for a return
(or newline, I suppose).  Clearly it's somehow getting confused about ioctls
(or at least, that's the way it seems to me). I'm guessing that I can look
for where it traps job-control signals, and do an appropriate ioctl right
after the return point. But what's causing this? "rn" does the same sort of
thing and it's not victim to this weirdness.

2) Occasionally, when I use fg to return to ELM, it prints "Alarm Clock" and
dies rather sloppily, leaving my mailbox in /tmp.  Does ELM not like staying
in the background for long periods of time?

Thanks,
---
Alexis Rosen
Owner/Sysadmin, PANIX Public Access Unix, NY
{cmcl2,apple}!panix!alexis

rmtodd@servalan.uucp (Richard Todd) (04/12/91)

alexis@panix.uucp (Alexis Rosen) writes:
>1) Often, when I ues job control to go off and do something, when I come back
>to ELM it no longer acts as soon as I type a character- it waits for a return
>(or newline, I suppose).  Clearly it's somehow getting confused about ioctls

>2) Occasionally, when I use fg to return to ELM, it prints "Alarm Clock" and
>dies rather sloppily, leaving my mailbox in /tmp.  Does ELM not like staying
>in the background for long periods of time?

Just as a wild guess, perhaps ELM is getting confused about signal handling
because of the SysV semantics being enabled by default.  Try sticking a 
call to set42sig() somewhere in the main() function and see if that helps.
I've found that's helped other programs that die strangely of "Alarm Clock",
and other programs as well -- as I recall, Epoch didn't work worth a damn
until I put the set42sig() in...
--
Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
	rmtodd@servalan.uucp
"Elvis has left Bettendorf!"

qfhca81@memqa.uucp (Henry Melton) (04/12/91)

> 
> Just as a wild guess, perhaps ELM is getting confused about signal handling
> because of the SysV semantics being enabled by default.  Try sticking a 
> call to set42sig() somewhere in the main() function and see if that helps.
> I've found that's helped other programs that die strangely of "Alarm Clock",
> and other programs as well -- as I recall, Epoch didn't work worth a damn
> until I put the set42sig() in...
> --
> Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
> 	rmtodd@servalan.uucp
> "Elvis has left Bettendorf!"

Great info!  set42sig let me compile oneko.  Keep these tips coming.



-- 
Henry Melton  qfhca81@memrqa.sps.mot.com 
{slow}  qfhca81@memqa   ..!cs.utexas.edu!execu!sequoia!memqa!qfhca81
{home}  henry@hutto     ..!emx.utexas.edu!hutto!henry

rudd@calvin.stanford.edu (Kevin Rudd) (04/13/91)

In article <23930@memqa.uucp> qfhca81@memqa.uucp (Henry Melton) writes:
>> 
>> Just as a wild guess, perhaps ELM is getting confused about signal handling
>> because of the SysV semantics being enabled by default.  Try sticking a 
>> call to set42sig() somewhere in the main() function and see if that helps.
>> I've found that's helped other programs that die strangely of "Alarm Clock",
>> and other programs as well -- as I recall, Epoch didn't work worth a damn
>> until I put the set42sig() in...
>> --
>> Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
>> 	rmtodd@servalan.uucp
>> "Elvis has left Bettendorf!"
>
>Great info!  set42sig let me compile oneko.  Keep these tips coming.
>
>
>
>-- 
>Henry Melton  qfhca81@memrqa.sps.mot.com 
>{slow}  qfhca81@memqa   ..!cs.utexas.edu!execu!sequoia!memqa!qfhca81
>{home}  henry@hutto     ..!emx.utexas.edu!hutto!henry

I was having the same problem and excitedly inserted set42sig() into my
elm main() function as the first statement and rebuilt elm.  Unfortunately,
after a while I received an "Alarm Clock" return to the shell as always.

Either there is something else going on or I put this in slightly wrong...

  -- Kevin

--
questions, comments, free two page monitors, contact kevin@trump.Stanford.EDU
complaints, bills, other crises, contact guido@outback.Mob.COM

mgchow@Apple.COM (Mike Chow) (04/15/91)

In article <23930@memqa.uucp> qfhca81@memqa.uucp (Henry Melton) writes:
>> 
>> Just as a wild guess, perhaps ELM is getting confused about signal handling
>> because of the SysV semantics being enabled by default.  Try sticking a 
>> call to set42sig() somewhere in the main() function and see if that helps.
>> I've found that's helped other programs that die strangely of "Alarm Clock",
>> and other programs as well -- as I recall, Epoch didn't work worth a damn
>> until I put the set42sig() in...
>> --
>> Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
>> 	rmtodd@servalan.uucp
>> "Elvis has left Bettendorf!"
>
>Great info!  set42sig let me compile oneko.  Keep these tips coming.
>
>

I THINK the "-ZB" flag to the A/UX C compiler will implicitly set up BSD
signal semantics and BSD defines, so one might want to try this flag when
compiling BSD sources for A/UX.

My general rule of thumb is to use set42sig() when porting BSD or SunOS 
derived code to A/UX.  Telltale signs are sigvec stuff, use of select(),
and BSD signal types (eg, SIGWINCH).

Mike Chow
mgchow@apple.com

jim@jagubox.gsfc.nasa.gov (Jim Jagielski) (04/15/91)

In article <51509@apple.Apple.COM> mgchow@Apple.COM (Mike Chow) writes:
}In article <23930@memqa.uucp> qfhca81@memqa.uucp (Henry Melton) writes:
}>> 
}>> Just as a wild guess, perhaps ELM is getting confused about signal handling
}>> because of the SysV semantics being enabled by default.  Try sticking a 
}>> call to set42sig() somewhere in the main() function and see if that helps.
}>> I've found that's helped other programs that die strangely of "Alarm Clock",
}>> and other programs as well -- as I recall, Epoch didn't work worth a damn
}>> until I put the set42sig() in...
}>> --
}>> Richard Todd	rmtodd@uokmax.ecn.uoknor.edu  rmtodd@chinet.chi.il.us
}>> 	rmtodd@servalan.uucp
}>> "Elvis has left Bettendorf!"
}>
}>Great info!  set42sig let me compile oneko.  Keep these tips coming.
}>
}>
}
}I THINK the "-ZB" flag to the A/UX C compiler will implicitly set up BSD
}signal semantics and BSD defines, so one might want to try this flag when
}compiling BSD sources for A/UX.
}


Now I don't know about 2.0.1, but for 2.0 and previous, even with -lbsd and
-ZB you STILL had to add the set42sig() call... it didn't "do it" for you :(

--
===========================================================================
#include <std/disclaimer.h>
                                 =:^)
           Jim Jagielski                    NASA/GSFC, Code 711.1
     jim@jagubox.gsfc.nasa.gov               Greenbelt, MD 20771

 "I object to all this sex on the television. I mean, I keep falling off!"