1996-02-13 08:29:09 -08:00
|
|
|
include ../config/Makefile
|
1995-07-02 09:42:16 -07:00
|
|
|
|
1995-07-18 01:41:12 -07:00
|
|
|
CC=$(NATIVECC)
|
1995-10-10 05:44:52 -07:00
|
|
|
FLAGS=-I../byterun -DNATIVE_CODE -DTARGET_$(ARCH) -DSYS_$(SYSTEM)
|
|
|
|
CFLAGS=$(FLAGS) -O $(NATIVECCCOMPOPTS)
|
|
|
|
DFLAGS=$(FLAGS) -g -DDEBUG $(NATIVECCCOMPOPTS)
|
1995-07-18 01:41:12 -07:00
|
|
|
|
|
|
|
COBJS=main.o fail.o roots.o signals.o \
|
|
|
|
misc.o freelist.o major_gc.o minor_gc.o memory.o alloc.o compare.o ints.o \
|
|
|
|
floats.o str.o array.o io.o extern.o intern.o hash.o sys.o parsing.o \
|
1996-02-25 09:53:56 -08:00
|
|
|
gc_ctrl.o terminfo.o md5.o obj.o lexing.o
|
|
|
|
|
1995-07-10 02:48:27 -07:00
|
|
|
ASMOBJS=$(ARCH).o
|
1995-07-12 07:27:10 -07:00
|
|
|
|
1995-07-18 01:41:12 -07:00
|
|
|
OBJS=$(COBJS) $(ASMOBJS)
|
|
|
|
DOBJS=$(COBJS:.o=.d.o) $(ASMOBJS)
|
1995-07-10 02:48:27 -07:00
|
|
|
|
1995-07-21 02:03:58 -07:00
|
|
|
all: libasmrun.a
|
1995-07-10 02:48:27 -07:00
|
|
|
|
|
|
|
libasmrun.a: $(OBJS)
|
|
|
|
rm -f libasmrun.a
|
|
|
|
ar rc libasmrun.a $(OBJS)
|
|
|
|
$(RANLIB) libasmrun.a
|
|
|
|
|
|
|
|
libasmrund.a: $(DOBJS)
|
|
|
|
rm -f libasmrund.a
|
|
|
|
ar rc libasmrund.a $(DOBJS)
|
|
|
|
$(RANLIB) libasmrund.a
|
|
|
|
|
1995-07-21 02:03:58 -07:00
|
|
|
install:
|
|
|
|
cp libasmrun.a $(LIBDIR)
|
|
|
|
cd $(LIBDIR); $(RANLIB) libasmrun.a
|
|
|
|
|
1996-07-03 11:39:36 -07:00
|
|
|
power.o: power-$(SYSTEM).o
|
|
|
|
cp power-$(SYSTEM).o power.o
|
1996-07-03 09:14:11 -07:00
|
|
|
|
1995-07-18 02:45:16 -07:00
|
|
|
misc.c: ../byterun/misc.c
|
|
|
|
ln -s ../byterun/misc.c misc.c
|
|
|
|
freelist.c: ../byterun/freelist.c
|
|
|
|
ln -s ../byterun/freelist.c freelist.c
|
|
|
|
major_gc.c: ../byterun/major_gc.c
|
|
|
|
ln -s ../byterun/major_gc.c major_gc.c
|
|
|
|
minor_gc.c: ../byterun/minor_gc.c
|
|
|
|
ln -s ../byterun/minor_gc.c minor_gc.c
|
|
|
|
memory.c: ../byterun/memory.c
|
|
|
|
ln -s ../byterun/memory.c memory.c
|
|
|
|
alloc.c: ../byterun/alloc.c
|
|
|
|
ln -s ../byterun/alloc.c alloc.c
|
|
|
|
compare.c: ../byterun/compare.c
|
|
|
|
ln -s ../byterun/compare.c compare.c
|
|
|
|
ints.c: ../byterun/ints.c
|
|
|
|
ln -s ../byterun/ints.c ints.c
|
|
|
|
floats.c: ../byterun/floats.c
|
|
|
|
ln -s ../byterun/floats.c floats.c
|
|
|
|
str.c: ../byterun/str.c
|
|
|
|
ln -s ../byterun/str.c str.c
|
|
|
|
io.c: ../byterun/io.c
|
|
|
|
ln -s ../byterun/io.c io.c
|
|
|
|
extern.c: ../byterun/extern.c
|
|
|
|
ln -s ../byterun/extern.c extern.c
|
|
|
|
intern.c: ../byterun/intern.c
|
|
|
|
ln -s ../byterun/intern.c intern.c
|
|
|
|
hash.c: ../byterun/hash.c
|
|
|
|
ln -s ../byterun/hash.c hash.c
|
|
|
|
sys.c: ../byterun/sys.c
|
|
|
|
ln -s ../byterun/sys.c sys.c
|
|
|
|
parsing.c: ../byterun/parsing.c
|
|
|
|
ln -s ../byterun/parsing.c parsing.c
|
|
|
|
gc_ctrl.c: ../byterun/gc_ctrl.c
|
|
|
|
ln -s ../byterun/gc_ctrl.c gc_ctrl.c
|
|
|
|
terminfo.c: ../byterun/terminfo.c
|
|
|
|
ln -s ../byterun/terminfo.c terminfo.c
|
1995-10-10 05:44:52 -07:00
|
|
|
md5.c: ../byterun/md5.c
|
|
|
|
ln -s ../byterun/md5.c md5.c
|
1995-07-18 02:45:16 -07:00
|
|
|
obj.c: ../byterun/obj.c
|
|
|
|
ln -s ../byterun/obj.c obj.c
|
1996-02-25 09:53:56 -08:00
|
|
|
lexing.c: ../byterun/lexing.c
|
|
|
|
ln -s ../byterun/lexing.c lexing.c
|
1995-07-18 02:45:16 -07:00
|
|
|
|
1996-04-30 07:53:58 -07:00
|
|
|
LINKEDFILES=misc.c freelist.c major_gc.c minor_gc.c memory.c alloc.c \
|
|
|
|
compare.c ints.c floats.c str.c io.c extern.c intern.c hash.c sys.c \
|
|
|
|
parsing.c gc_ctrl.c terminfo.c md5.c obj.c lexing.c
|
|
|
|
|
|
|
|
clean::
|
|
|
|
rm -f $(LINKEDFILES)
|
|
|
|
|
1995-10-31 01:27:04 -08:00
|
|
|
.SUFFIXES: .asm .S .d.o
|
1995-07-02 09:42:16 -07:00
|
|
|
|
|
|
|
.asm.o:
|
|
|
|
$(AS) $(ASFLAGS) -o $*.o $*.asm
|
|
|
|
|
1995-10-31 01:27:04 -08:00
|
|
|
.S.o:
|
|
|
|
$(CC) -c $(ASFLAGS) $*.S
|
|
|
|
|
1995-07-10 02:48:27 -07:00
|
|
|
.c.d.o:
|
1995-07-18 01:41:12 -07:00
|
|
|
@ if test -f $*.o; then mv $*.o $*.f.o; else :; fi
|
|
|
|
$(CC) -c $(DFLAGS) $<
|
|
|
|
mv $*.o $*.d.o
|
|
|
|
@ if test -f $*.f.o; then mv $*.f.o $*.o; else :; fi
|
1995-07-10 02:48:27 -07:00
|
|
|
|
1995-07-02 09:42:16 -07:00
|
|
|
clean::
|
|
|
|
rm -f *.o *.s *.a *~
|
1995-07-07 05:07:32 -07:00
|
|
|
|
1995-10-10 05:44:52 -07:00
|
|
|
depend: $(COBJS:.o=.c)
|
|
|
|
gcc -MM $(FLAGS) *.c > .depend
|
|
|
|
gcc -MM $(FLAGS) -DDEBUG *.c | sed -e 's/\.o/.d.o/' >> .depend
|
1995-07-10 02:48:27 -07:00
|
|
|
|
|
|
|
include .depend
|
|
|
|
|