# Copyright (c): Uwe Schmidt, FH Wedel # # You may study, modify and distribute this source code # FOR NON-COMMERCIAL PURPOSES ONLY. # This copyright message has to remain unchanged. # # Note that this document is provided 'as is', # WITHOUT WARRANTY of any kind either expressed or implied. SRC = IntMap.c BitString.c IntMapTest.c time = /usr/bin/time --format="runtime was %U sec" include ../rules.mk ##all ## make all targets ## for normal version: all1 ## without debug: ndebug ## and for iterative versions: iterative all : $(MAKE) ndebug prof ndebug : $(MAKE) CCFLAGS='$(CCFLAGS) -O2 \ -DNDEBUG=1 -DTRACE=0 -DQUIET=0' IntMapTest prof : $(MAKE) CCFLAGS='$(CCFLAGS) -pg \ -DNDEBUG=1 -DTRACE=0 -DQUIET=1' IntMapProfTest run : ./IntMapTest @$(time) ./IntMapTest profrun : ./IntMapProfTest rm -f gmon.out ./IntMapProfTest gprof --brief IntMapProfTest gmon.out distclean : $(MAKE) clean rm -f ./IntMapProfTest ./IntMapTest gmon.out IntMap.o : IntMap.h BitString.h BitString.o : BitString.h IntMapTest : IntMap.h IntMapTest : $(OBJ) $(CC) -o $@ $(OBJ) $(CCFLAGS) IntMapProfTest : $(SRC) IntMap.h BitString.h $(CC) -o $@ $(SRC) $(CCFLAGS) .PHONY : all ndebug run clean distclean indent profrun