X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;ds=sidebyside;f=bfile%2FMakefile;h=52fff4dacc00e949e46310298aece36bba993aa0;hb=f03a35208f8b0fb19b79708c60153f6e522c1074;hp=b4cee7030646c97e0d5ed3949461ce389fdd0cd9;hpb=4186e44a259b3982abc5f11c68973bfb05ea6615;p=idzebra-moved-to-github.git diff --git a/bfile/Makefile b/bfile/Makefile index b4cee70..52fff4d 100644 --- a/bfile/Makefile +++ b/bfile/Makefile @@ -1,11 +1,10 @@ - SHELL=/bin/sh INCLUDE=-I../include TPROG=btest -CFLAGS=-g -Wall +CFLAGS=-g -Wall -pedantic -ansi DEFS=$(INCLUDE) LIB=../lib/bfile.a -PO = open.o close.o rdwr.o +PO = bfile.o mfile.o CPP=cc -E all: $(LIB) @@ -22,11 +21,21 @@ $(LIB): $(PO) $(CC) -c $(DEFS) $(CFLAGS) $< clean: - rm -f *.[oa] $(TPROG) core mon.out gmon.out + rm -f *.[oa] $(TPROG) core mon.out gmon.out errlist + +depend: depend2 -dep depend: - $(CPP) $(INCLUDE) -M *.c >.depend +depend1: + mv Makefile Makefile.tmp + sed '/^#Depend/q' Makefile + $(CPP) $(INCLUDE) -M *.c >>Makefile + -rm Makefile.tmp -#ifeq (.depend,$(wildcard .depend)) +depend2: + $(CPP) $(INCLUDE) -M *.c >.depend + +ifeq (.depend,$(wildcard .depend)) include .depend -#endif +endif + +#Depend --- DOT NOT DELETE THIS LINE