An lcc back end for the x86 under Linux.

(Edited from the a.out version for ELF by Ken.Yap@syd.dit.csiro.au.)

This distribution contains the following files and directories.

README.linux (this file)
etc/linux.c
include/x86/linux/assert.h
include/x86/linux/errno.h
include/x86/linux/math.h
include/x86/linux/float.h
include/x86/linux/limits.h
include/x86/linux/signal.h
include/x86/linux/stdlib.h
include/x86/linux/time.h
include/x86/linux/ctype.h
include/x86/linux/locale.h
include/x86/linux/stddef.h
include/x86/linux/setjmp.h
include/x86/linux/stdio.h
include/x86/linux/string.h
include/x86/linux/stdarg.h
include/x86/linux/asm/types.h
src/bind.c
src/linux.c
src/linux.md
src/makefile
src/run
x86/linux/
x86/linux/tst/

Install the distribution by extracting it on top of an existing lcc 3.4
hierarchy. This distribution WILL NOT WORK with lcc 3.2. Extract the
distribution with

cd /usr/local/src/lcc
gunzip -c <linux.tar.gz | tar xpof -

If you've installed lcc in different directories, edit these
instructions accordingly. 

Note that src/{bind.c,makefile,run} will overwrite the 3.4 versions of
these files. bind.c includes the binding for x86-linux, makefile
includes rules for linux.c, and run omits lcc's -N flag.

Build and install the lcc driver (edit the paths in etc/linux.c,
if necessary):

cd /usr/local/src/lcc
cd etc
make HOST=linux
mv a.out /usr/local/bin/lcc

Build and install rcc, the compiler proper, and clean up:

cd /usr/local/src/lcc
cd x86/linux
make CC=gcc -f ../../src/makefile
make -f ../../src/makefile TARGET=x86-linux triple
mv rcc /usr/local/lib
make -f ../../src/makefile clobber

The triple test may produce harmless diagnostics like

	od rcc +8 >od2
	od: +8: No such file or directory
	can't make -f ../../src/makefile TARGET=x86-linux triple

For production use, you will need to create an include directory for lcc
specific header files:

mkdir /usr/local/include/ansi /usr/local/include/ansi/asm
touch asm/byteorder.h

Others may be needed to override gcc specific ones, in particular those
that use assembly language inserts. Please send updates to the archive
as you discover new ones.

The test suite fails in paranoia but that is because of the signal.h
included in this distribution. If this is removed so that the Linux one
is used, all the tests are passed. I don't know if this can be safely
removed and not affect the bootstrap. I think it's ok, can somebody
confirm this please. In fact all the included header files should be
checked to see if they are really necessary for the bootstrap and
testing suite.

The -g and -p flags in this lcc pass the same flags to ld that gcc does
but don't seem to generate the correct code. Another one for the TODO
list.

Thanks to Thorsten Ohl (Thorsten.Ohl@Physik.TH-Darmstadt.de), Bob
Mercier (mercier@kaiwan.com), and Mary Fernandez (mff@cs.princeton.edu)
for most of the work, and to Norman Ramsey (norman@bellcore.com)
for checking the beta distributions.

Greg Humphreys / humper@cs.princeton.edu

modified Tue Nov 14 01:04:21 EST 1995 by ken
modified Mon Jul 10 16:17:05 EDT 1995 by drh
modified Mon May 29 10:50:34 EDT 1995 by drh
modified Tue May 23 13:49:56 EDT 1995 by drh
modified Wed May 17 15:18:13 EDT 1995 by drh
modified Fri May 12 15:02:16 EDT 1995 by drh
modified Thu May 11 11:12:27 EDT 1995 by drh
created  Fri May  5 14:02:51 EDT 1995 by humper
