[comp.unix.xenix] Available: GCC/GAS Patches for SCO Xenix Dev. Sys.

steve@robobar.co.uk (Steve Bleazard) (03/19/90)

I have taught GCC and GAS to produce .o files which are usable
under SCO Xenix 386.

Relevant information:

    * Currently, the patches are relative to GCC 1.37 and GAS 1.34.

    * requires Microsoft C 5.1 for 386 (SCO lng 085 or better) for stage 1
      build.

    * Produces Microsoft C compatible OMF object files.

    * Links with the standard Xenix 386 libraries (at least it does with
      my 2.3 dev. sys. libraries) using the standard ld(C) to produce
      x.out files executable by SCO Xenix 386.

    * GCC compiles itself (with -O) comparing .o files with no differences
      between stage 3 and stage 4. (Yes, you can just do cmp file1.o file2.o)

    * compiles perl release 3.0 patchlevel 15 and runs all the tests
      successfully, but not with -O (That makes it core dump :-( )
      (Had to use -fpcc-struct-return to make it pass op.dbm test)

My system:

	SCO Xenix 2.3.2 with 2.3 dev sys and lng 085.
	I've compiled it with only 2 Mb of core in the box, but that makes
	it swap just a bit.  It's fine now (there's 8 Mb in it today :-).

Patch availability:

	If there's enough interest, I'll post the patches to alt.sources
	next week or so.  No, I'm not mailing them overseas, Eunet costs
	are low, but not _that_ low.

	I will mail them to archive sites, if asked.

-- 
Steve.Bleazard@RoboBar.Co.Uk        | Phone:  +44 1 991 1142 x153
Snr Software Engineer, Robobar Ltd. | Fax:    +44 1 998 8343 (G3)
22 Wadsworth Road, Perivale.        |
Middx., UB6 7JD ENGLAND.            | ...!ukc!ibmpcug!robobar!steve

steve@robobar.co.uk (Steve Bleazard) (03/23/90)

In article <1990Mar19.134213.20819@robobar.co.uk> I wrote:

[ concerning the imminent posting of the patches to make GCC/GAS work
  unde SCO Xenix 386 ]

The first of two coordinated patches is now out, posted to alt.sources.
The second will come after lunch.

>     * Currently, the patches are relative to GCC 1.37 and GAS 1.34.
In fact, the gas patch works relative to gas 1.35 as well, and we just built
GCC 1.37.1 with no changes to the GCC patch.

>     * compiles perl release 3.0 patchlevel 15 and runs all the tests
>       successfully, but not with -O (That makes it core dump :-( )

Fixed. Perl 3.0pl15 compiled with gcc -O now passes all tests.  Guess what
has just become my default compiler ?

> 	If there's enough interest, I'll post the patches to alt.sources
> 	next week or so.

There was adequate interest.  You don't need to mail me anymore if all
you want to do is express interest.

There was also some call for a binary distribution.  I am not on the Internet,
and e-mail costs from Britain to anywhere else is prohibitively high.

Those who are _desperate_ may mail me a single 1.2 Mb floppy WITH AN EXTRA
SELF-ADDRESSED MAILER ENCLOSED, and I'll stick a binary distribution on
it and send it back to you by return of post (aren't I nice).

I would also be interested to hear if you could provide Internet and/or
anon UUCP homes for the both patch and binary distributions in your
respective countries so I can refer people to you.

To quote Len,

Enjoy!
-- 
Steve.Bleazard@RoboBar.Co.Uk        | Phone:  +44 1 991 1142 x153
Snr Software Engineer, Robobar Ltd. | Fax:    +44 1 998 8343 (G3)
22 Wadsworth Road, Perivale.        |
Middx., UB6 7JD ENGLAND.            | ...!ukc!ibmpcug!robobar!steve

ronald@robobar.co.uk (Ronald S H Khoo) (03/24/90)

In article <1990Mar23.090407.11111@robobar.co.uk> steve@robobar.co.uk (Steve Bleazard) writes:

[ concerning his GCC port to Xenix ]

Hmm, My proofreading isn't as good as it was :-(  One thing that got left out
of the README was:

	Behaviour of -m80387 flag is a little non-intuitive.  If you specify
	-m80387, the symbol __fltused is emitted whether or not floating
	point instructions are generated.  In this case, floating point
	opcodes are generated inline.  The correct printf is therefore loaded
	and the program works.

	If you do _not_ specify -m80387, but you _do_ have floating point
	operations in your code, GCC will make calls to routines in its
	gnulib, which themselves cause __fltused to be required, and again,
	all works OK, albeit a little slower.

	If, however, -m80387 is NOT specified and you DON'T have any
	floating operations which call gnulib floating ops, then the
	non-float compatible printf will be loaded, and the program
	won't work.

Example:
	% cat x.c
	main()
	{
		printf("%f\n", 1.0);
	}
	% gcc x.c
	% ./a.out
	f
	% gcc -m80387 x.c
	% ./a.out
	1.000000

So, if you need to print floating point numbers, you _may_ need to say
-m80387.  You might as well say -m80387 ANYWAY.  The cost is about
5k if you don't have any float stuff (peanuts!).  This will be the
default if you #define TARGET_DEFAULT to 1 in tm.h (config/tm-xenix386.h)
In this case, -msoft-float will force the use of gnulib and not emit __fltused.

Ho Hum.

-- 
Eunet: Ronald.Khoo@robobar.Co.Uk   Phone: +44 1 991 1142    Fax: +44 1 998 8343
Paper: Robobar Ltd. 22 Wadsworth Road, Perivale, Middx., UB6 7JD ENGLAND.

klarich@a.cs.okstate.edu (Terry Klarich) (03/24/90)

I am very interested in those patches.  Please, by all means, post them as
soon as possible.


------------------------------------------------------------------------------
Terry Klarich (klarich@a.cs.okstate.edu) n5hts
A man is not complete until he is married then, he is finished.

jeff@hobbes.C2S.MN.ORG (Jeff Holmes) (03/26/90)

In article <1990Mar23.090407.11111@robobar.co.uk> steve@robobar.co.uk (Steve Bleazard) writes:
> In article <1990Mar19.134213.20819@robobar.co.uk> I wrote:
> 
> [ concerning the imminent posting of the patches to make GCC/GAS work
>   unde SCO Xenix 386 ]
> 
> The first of two coordinated patches is now out, posted to alt.sources.
> The second will come after lunch.

	This is great!

	Anyone looked at GDB yet?

	--
	Jeff
Jeff Holmes	                  DOMAIN: jeff@questar.mn.org 
Questar Data Systems                UUCP: amdahl!bungia!questar!jeff
St. Paul, MN 55121		    AT&T: +1 612 688 0089

ron@rdk386.uucp (Ron Kuris) (03/28/90)

In article <5378@questar.QUESTAR.MN.ORG> jeff@hobbes.QUESTAR.MN.ORG (Jeff Holmes) writes:
>
>	This is great!
>
>	Anyone looked at GDB yet?
>
Yup.  I've successfully ported GDB to Xenix.  Works on the standard cc.
Even reads the debugging information.  I want to implement partial symtabs
for it before it goes out (seems too slow starting up).  If you're
interested in the preliminary patches, I might be able to accomodate you.

I am very interested in the alt.sources gas/gcc patches.  I missed them on
alt.sources.  Can someone close by arrange to mail them to me?

/-----------------------------------\/\/\/\
| {unify|{sactoh0!siva}}!rdk386!ron | o o |
| Cut this out and present it to me |  -  |
| for a FREE $20.00 bill!  Expires  | awk |
| upon presentation.                |     |
\-----------------------------------/     \

-- 
/-----------------------------------\/\/\/\
| {unify|{sactoh0!siva}}!rdk386!ron | o o |
| Cut this out and present it to me |  -  |
| for a FREE $20.00 bill!  Expires  | awk |