# Makefile # Last edited on 2003-08-31 18:33:56 by stolfi LIBNAME = libminu HFILES = \ minu_gen.h \ minu_js.h \ minu_brent.h \ minu_herm.h CFILES = \ minu_gen.c \ minu_js.c \ minu_brent.c \ minu_herm.c LIBFILE = \ ${LIBNAME}.a .PHONY: all clean uninstall install test # all: clean uninstall install all: uninstall install # all: test HOFILES = ${subst .h,.ho,${HFILES}} OFILES = ${subst .c,.o,${CFILES}} uninstall: cd ${INC} && /bin/rm -f ${HFILES} ${HOFILES} cd ${LIB} && /bin/rm -f ${LIBFILE} install: ${HOFILES} ${LIBFILE} cp -p ${HFILES} ${INC} cp ${HOFILES} ${INC} cp -p ${LIBFILE} ${LIB} test: cd tests && make all clean: -/bin/rm -f *.o *.ho *.a core cd tests && make clean # ====================================================================== INC = /home/staff/stolfi/PUB/include LIB = /home/staff/stolfi/PUB/${PLATFORM}/lib GCCFLAGS = \ -I. -I${INC} \ -g \ -Wall -Wpointer-arith -Wmissing-prototypes %.o: %.c ;\ gcc -c ${GCCFLAGS} $*.c %.ho: %.h ;\ gcc -o $*.ho -c ${GCCFLAGS} -x c $*.h \ || /bin/rm -f $*.ho ${LIBFILE}: ${OFILES} ;\ rm -f $*.a && ar crv $*.a ${OFILES} && ranlib $*.a OPTFLAGS = -g CFLAGS = \ -I. -I${INCDIR} \ ${OPTFLAGS} \ -Wall -Wpointer-arith -Wmissing-prototypes minu_gen.ho: minu_js.ho: minu_gen.ho minu_brent.ho: minu_gen.ho minu_herm.ho: minu_gen.ho minu_gen.o: minu_gen.ho minu_js.o: minu_js.ho minu_gen.ho minu_brent.o: minu_brent.ho minu_gen.ho minu_herm.o: minu_herm.ho minu_gen.ho