######################################################################
#
#  Name ........................ LiDIA/src/kernel/libI/Sparc7/makefile
#
#  Architecture : sparc7, sparc8, mips, linux
#  Compiler     : gcc, g++ 
#  Flags        : -g -O2
#  Program Flags: -DDEBUG, -DMEMORY, -DERRIGN 
#  Author       : Papanikolaou Thomas 
#  Release      : 1.0 
#  Last Change  : Mon Apr 11 16:09:08 MET DST 1994 
#  Copyright    : by the University of Saarland, 1994 
#

#
# include the configuration file
#

include ../../../../../config/CONFIG

#
# Rules
#

.c.o:
	$(CC) -c $(CFLAGS) $(KERNEL_FLAGS) -I.. $<

.s.o:
	-$(CP) $< tmp-$*.c
	$(CC) -E $(ASPPFLAGS) tmp-$*.c > tmp-$*.ss
	./lcpp < tmp-$*.ss > tmp-$*.s 
	$(AS) tmp-$*.s -o $@
	-$(RM) tmp-$*.ss
	-$(RM) tmp-$*.c
	-$(RM) tmp-$*.s

#
# SUNPRO
# .s.o:
#	$(AS) -P $(ASPPFLAGS) $<  -o $@

#
# Digit functions
#

DOBJ=idigitvec.o idigitkara.o idigitdiv.o idigitaddsubmult.o \
	idigitvecmultadd.o idigitvecmultsub.o idigitvecmult.o \
	idigitveccsubto.o

all: lcpp $(DOBJ)

lcpp:	lcpp.c
	$(CC) lcpp.c -o lcpp


idigitvec.o:	../iint.h ../idigit.h
idigitkara.o:	../iint.h ../idigit.h

clean:
	-$(RM) lcpp *.o *% *.out
