TOPDIR=../
include $(TOPDIR)Rules.make

all: cphelper.so cphlpif.so

clean:
	rm -f *.so *.o

cphelper.o: cphelper.c cphelper.h \
	../config.h \
	../types.h \
	../boot/psetting.h \
	../stuff/poutput.h \
	../boot/plinkman.h \
	../stuff/err.h \
	../boot/pmain.h \
	../binfile/binfpak.h
	$(CC) cphelper.c -o $@ -c

cphelper_so=cphelper.o
cphelper.so: $(cphelper_so)
	$(CC) -shared -o $@ $^

cphlpif.o: cphlpif.c cphelper.h \
	../config.h \
	../types.h \
	../boot/plinkman.h \
	../stuff/poutput.h \
	../stuff/framelock.h \
	../cpiface/cpiface.h \
	../boot/pmain.h \
	../stuff/err.h
	$(CC) cphlpif.c -o $@ -c

cphlpif_so=cphlpif.o
cphlpif.so: $(cphlpif_so)
	$(CC) -shared -o $@ $^
