#
# stub-PCR makefile 
#

CFLAGS= -g -O2 -I.

SRCS= sThreads.c sThreadsDynamicEnvironment.c sGCfinalize.c sIncrementalLoad.c sMisc.c sUIO.c sEmuHDieee.c

OBJS= sThreads.o sThreadsDynamicEnvironment.o sGCfinalize.o sIncrementalLoad.o sMisc.o sUIO.o sEmuHDieee.o sMachDep.o

HEADERS= xr/BasicTypes.h xr/GC.h xr/IncrementalLoad.h xr/IncrementalLoadPrivate.h xr/UnixSysCallTranslation.h xr/Threads.h xr/ThreadsBackdoor.h xr/ThreadsDynamicEnvironment.h xr/ThreadsMsg.h xr/ThreadsSharedMem.h xr/ThreadsTermination.h xr/UnixSysCallTranslation.h xr/sMisc.h xr/UIO.h xr/UIOBasic.h 

all: spcr.o

spcr.o: gc/gc.a $(OBJS)
	-ld -r -o spcr.o $(OBJS) gc/gc.a

$(OBJS): $(HEADERS)

sMachDep.o: sMachDep.s
	${AS} -o sMachDep.o -P ${AFLAGS} sMachDep.s

gc/gc.a:
	cd gc; make gc.a