From: aew...@leonard.anu.edu.au (Anthony Edward Wesley)
Subject: Story + Question for iBCS developers
Date: 1996/09/20
Message-ID: <51sn23$s2p@leonard.anu.edu.au>#1/1
X-Deja-AN: 184092791
organization: Australian National University
keywords: iBCS,XENIX
newsgroups: comp.os.linux.development.system


[ This will also be sent to the iBCS mailing list ]

Greetings all...

I have a story (moderately long) about trying to use the iBCS module which
might be of interest to those on the list, and also a question at the
end (for those developers who may be able to answer)...

The Story
---------

I have a business client who is running on SCO XENIX 2.3, and I would like
very much to liberate them and run Linux instead, as I have been a keen
Linux user for several years.

When I heard about the iBCS module, I thought that this might be one
way to do it. I was more encouraged when I tried their SCO database and
found that it would run under the emulator - but then I struck problems.
Their database system (FilePro) is a collection of shell scripts and 386
executables which rely heavily on the system tools (/bin and /usr/bin). As
you would imagine, there are significant differences between the XENIX and
Linux versions of these tools, so lots of things did not work properly.

This had me stumped for a while, but then I thought "why not run the entire
XENIX system under the emulator? Including the xenix versions of all system 
tools etc as well as the FilePro database." So I installed a full xenix system
under /usr/local/xenix on my Linux box, installed the iBCS module and tried
again...

Still there are problems. It seems that many of the xenix tools are not 386
model binaries, and crash with "Memory fault" or "Stack overflow" when they
are run. For example, here is what "file" thinks of the xenix version of
mkdir:

	mkdir:
	setuid Microsoft a.out separate pure segmented
	fixed-stack word-swapped 86 small model executable

Any attempt to run this program causes a memory fault. Compare that to 
the xenix version of awk (which runs fine):

	awk:
	Microsoft a.out separate pure segmented word-swapped 386
	small model executable

The difference appears to be crucial. Anything which is _not_ identified
as a 386 model binary crashes (yes, I have read the release notes for iBCS,
where it says that iBCS supports 386 binaries only. sigh).

This leaves me with the possibility of running a hybrid system - use the XENIX
binaries wherever possible to give the impression of a true xenix system to
the database, but substitute Linux tools for those which will not work. I do
not look forward to this solution, as it seems quite fragile and will require
significant work to accomplish. What else can I do ?

The Question
------------

It is made clear in the release notes for iBCS that there is support only
for 386 model binaries. How much work is involved in developing support for
binaries such as "mkdir" (see above) ?? If it is considered feasible by 
those who are involved in this development, then I'll volunteer to have a
go at it - I am an experienced C/UNIX/DOS/Hardware engineer so it should not
be outside my ability to do it (assuming that it is feasible at all!).

I am guessing that the executables that I am having trouble with contain
16-bit code segments, and interfacing that with the Linux kernel might be
"interesting" to say the least.

I look forward to hearing from someone who Knows...

Cheers, Anthony

Anthony.Wes...@anu.edu.au

From: ja...@purplet.demon.co.uk (Mike Jagdis)
Subject: Story + Question for iBCS developers
Date: 1996/09/22
Message-ID: <1019.32470E27@purplet.demon.co.uk>#1/1
X-Deja-AN: 184886420
x-mail2news-path: news.demon.net!purplet.demon.co.uk
sender: ufg...@purplet.demon.co.uk (newsout1.26)
x-nntp-posting-user: ja...@purplet.demon.co.uk
organization: FidoNet node 2:252/305 - The Purple Tentacle, Reading
newsgroups: comp.os.linux.development.system


* In message <51sn23$...@leonard.anu.edu.au>, Anthony Edward Wesley said:

AW> It is made clear in the release notes for iBCS that there is
AW> support only for 386 model binaries.

You must have a pretty ancient release of iBCS then. There has been basic 
Xenix 286 support, in the form of x286emul, for a long time. It isn't 
complete, it isn't perfect, it requires an a.out compiler to build it and it 
isn't currently being developed by anyone. However it does work for many 
binaries.

                                Mike  

From: aew...@leonard.anu.edu.au (Anthony Edward Wesley)
Subject: Re: Story + Question for iBCS developers
Date: 1996/09/25
Message-ID: <52ab3k$bim@leonard.anu.edu.au>#1/1
X-Deja-AN: 185178659
references: <1019.32470E27@purplet.demon.co.uk>
organization: Australian National University
newsgroups: comp.os.linux.development.system


ja...@purplet.demon.co.uk (Mike Jagdis) writes:

>* In message <51sn23$...@leonard.anu.edu.au>, Anthony Edward Wesley said:

>AW> It is made clear in the release notes for iBCS that there is
>AW> support only for 386 model binaries.

>You must have a pretty ancient release of iBCS then. There has been basic 
>Xenix 286 support, in the form of x286emul, for a long time. It isn't 
>complete, it isn't perfect, it requires an a.out compiler to build it and it 
>isn't currently being developed by anyone. However it does work for many 
>binaries.

>                                Mike  
> 

I have the latest iBCS, and yes there is x286emul included. I have
compiled/installed it (didn't say anything about needing an a.out compiler, and
it built apparently ok on my 2.0.14 elf system). It did change the type of error
message that I get when running 8086 binaries from "Segmentation fault" to
"Stack overflow" but I was unable to find any 8086 binaries that would work.

I just assumed that since it was marked "incomplete and unsupported" that it no
longer worked with recent releases of iBCS. If anyone has a recent iBCS that is
successfully running SCO Xenix 2.3 8086 binaries then I would very much like
to hear from them!

Regards, Anthony


Anthony Wesley
Anthony.Wes...@anu.edu.au