# $RCSfile: Makefile,v $ # $Revision: 1.1 $ # $Date: 1994/09/15 02:37:53 $ CC = gcc CFLAGS= -g -ansi -Wall # files associated with the bitstring package HDRS = bits.h SRCS = bits.c OBJECTS = bits.o # files associated with the test driver DHDRS = DSRCS = driver.c DOBJECTS = driver.o # this is the default target all :: driver # This rule identifies how to make objects from sources %.o:%.c $(CC) $(CFLAGS) -c $< # this rule generates our test driver driver: $(OBJECTS) $(DOBJECTS) $(CC) $(CFLAGS) $(OBJECTS) $(DOBJECTS) -o driver # this rule removes unwanted object modules # the - in front of the command ignores errors clean: - /bin/rm $(OBJECTS) $(DOBJECTS) # this rule wraps up stuff in a shar file shar: shar Makefile $(SRCS) $(HDRS) $(DSRCS) $(DHDRS) > bits.shar # this rule wraps stuff up in a tar file tar: tar cvf - Makefile $(SRCS) $(HDRS) $(DSRCS) $(DHDRS) > bits.tar # this rule determines the dependencies between code and header files # and saves us from having to do it. # You should do a make depend after every re-organization of the files that # would alter dependencies. depend: makedepend $(SRCS) $(DSRCS) # DO NOT DELETE THIS LINE -- make depend depends on it. bits.o: /usr/include/stdio.h bits.h driver.o: /usr/include/stdio.h bits.h