GCC/GAS Patches for SCO Xenix 386 (Patch 1 of 2)
Ademola Taiwo
adtaiwo at athena.mit.edu
Mon Mar 26 06:39:49 AEST 1990
Hi frustrated xenix user,
The above patch is genuine works great and less filling!
So this is the real life experience of bringing xenix down on its
knees and accepting GNU.
0: Absolutely important.
Get the patches to GAS that was posted a few days ago on
alt.sources and build gas.
1. Building GCC from OLDCC (A very painful exercise)
A. Copy the files named below from the standard include directory.
You will need to throw wrappers around the varaibles listed.
stdarg.h: *va_list
stdlib.h: size_t
string.h: size_t
stdio.h: size_t, fpos_t, time_t, *va_list
time.h size_t, clock_t, time_t
sys/types.h: time_t
for example in stdarg.h modify the line
typedef char *va_list;
to
#ifndef _VA_LIST
#define _VA_LIST
typedef char *va_list;
#endif
B. In your source directory.
a. Apply the patches to GCC and do you config.gcc xenix386 as adviced.
b. Whimpy xenix preprocessor chokes n the following files, (the worst
part of it is that it chokes quietly passing the uncompleted file to the
compiler.) Anyway, the files are explow.c reload.c reload1.c recog.c
for each of the files
mv file.c file.gnu
c. Xenix c compiler chokes on #ifndef __FILE__, around line 163, move
the section into the comment above it.
C. In the directory you will be building gcc.
a. Edit the Makefile.
Remove all options that may temp OLDCC of thinking about optimization.
add -w to OLDCC options.
comment out the actions for config.status
Add a rule for making files that MSC chokes on. eg GNUmake groks
%.c:%.gnu
./cpp -P -DM_XENIX -DM_I386 -DUSG ${INCLUDES} $< > $@
mv $< $*.c
b. edit tm.h
change the 0 to 1 in TARGET_DEFAULT
#define TARGET_DEFAULT 1
c. make cpp
You need to build the gnu preprocessor you will need later. If
get scoping too deep message at this point, you have turned on the xenix
cc optimizer, you may restart or ignore the message.
c. make
You are now building gcc. Go and take a shower or grab dinner,
on my machine this take 45 minutes!!!
SIT BACK AND RELAX!!! FUN IS JUST STARTING.
2. Building GCC with gcc (EASY street, and a lot of fun)
A. Edit makefile and rmove all those things that talk about alloca
B. Type 'make bootstrap' and go for a walk
Goodluck!
I did this about 8 times, first few times to install gcc and
later to install protoize. Protoize installation is not for weak minds.
I am working on gcc groking -g on xenix. If you have questions
e-mail adtaiwo at athena.mit.edu
More information about the Comp.unix.xenix
mailing list