Port-vax archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Ultrix compatibility?

Hi all,

I am having trouble with Ultrix binary compatibility in -current.  It was
working in 2.0, but I haven't tried it since then.  I've played around
with setting various kernel options including COMPAT_ULTRIX, COMPAT_43,
COMPAT_VAX1K, and COMPAT_IBCS2.  My binary is a simple benchmark compiled
with cc on Ultrix 4.5; I also have one compiled with vcc that produces the
same behavior.  With most options my binary is treated as a shell script
and I get:

# ./flops-cc
./flops-cc: 1: Syntax error: word unexpected (expecting ")")

But if I turn all of the COMPAT_* options on, I get:

# ./flops-cc
[1]   Illegal instruction (core dumped) ./flops-cc
# ktrace ./flops-cc
[1]   Illegal instruction (core dumped) ktrace ./flops-cc
# kdump
     8      1 ktrace   EMUL  "netbsd"
     8      1 ktrace   RET   ktrace 0, 107/0x6b
     8      1 ktrace   CALL  execve(0x7ffffed7,0x7fffee28,0x7fffee30)
     8      1 ktrace   NAMI  "./flops-cc"
     8      1 flops-cc EMUL  "netbsd"
     8      1 flops-cc RET   execve JUSTRETURN
     8      1 flops-cc PSIG  SIGILL SIG_DFL: code=ILL_ILLOPC, addr=0x0,
     8      1 flops-cc NAMI  "flops-cc.core"

which appears to be the kernel forcing the program to run as a netbsd binary.

For curiosity's sake, I downloaded some ckermit binaries from
http://www.columbia.edu/kermit/ck80binaries.html for comparison. 
cku211.bsd43-vax, a 4.3BSD executable, works correctly if COMPAT_43 is on.
 cku197.ultrix3x-vax-3.0 starts to run but then dumps core. 
cku209.ultrix45-vax-4.5 gets as far as spitting out errors about not being
able to stat /etc/svc.conf (even though /emul/ultrix/etc/svc.conf exists)
and then dumps core.  I suspect the Ultrix binaries may actually be using
4.3BSD compatibility instead of Ultrix compatibility.

I'm at a loss here.  Normally I would go into the kernel source and throw
in some printf statements, but I wasn't able to grok the code sufficiently
to figure out where they should be going.  Does anyone have any

If anyone wants them, the binaries I was testing are at

-Henry Bent

P.S. Interestingly, NetBSD's "file" command says my binary is a "386
demand paged pure executable not stripped" but Solaris 10 knows that it is
a "VAX demand load format a.out object file not stripped".

Home | Main Index | Thread Index | Old Index