-default: libhtable.a
+LIBRARY = librrqhtable.a
+LIBOBJS = htable.o
-.INTERMEDIATE: htable.o
-htable.o: CFLAGS = -Wall -g
-htable.o: htable.c
+default: $(LIBRARY) example-htable
+CLEANRM += $(LIBRARY)
-libhtable.a: htable.o
- $(AR) r $@ $^
-CLEANRM += libhtable.a
+include ../common.mk
.INTERMEDIATE: example-htable.o
example-htable: CFLAGS = -Wall -g
-example-htable: LDLIBS = libhtable.a
-example-htable: example-htable.o libhtable.a
+example-htable: example-htable.o $(LIBRARY)
+
CLEANRM += example-htable
-clean:
- rm -f $(CLEANRM)