From 7edd0ced5c8e45161cb655a36f05f2a90283bb9e Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Fri, 5 Mar 2021 20:59:13 +0100 Subject: Join test source files into test.c and update MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 17f7774..41a9607 100644 --- a/Makefile +++ b/Makefile @@ -151,7 +151,7 @@ HDR =\ $(HDR_METHODS) -all: libgamma.a libgamma.$(LIBEXT) +all: libgamma.a libgamma.$(LIBEXT) test $(OBJ): $(@:.o=.c) $(HDR) $(LOBJ): $(@:.lo=.c) $(HDR) @@ -177,6 +177,12 @@ libgamma.$(LIBEXT): $(LOBJ) .c.lo: $(CC) -fPIC -c -o $@ $< $(CFLAGS) $(CFLAGS_METHODS) $(CPPFLAGS) $(CPPFLAGS_METHODS) +test.o: test.c libgamma.h + $(CC) -c -o $@ test.c $(CFLAGS) $(CPPFLAGS) + +test: test.o + $(CC) -o $@ test.o libgamma.a $(LDFLAGS_METHODS) $(LDFLAGS) + install: libgamma.a libgamma.$(LIBEXT) mkdir -p -- "$(DESTDIR)$(PREFIX)/lib/" mkdir -p -- "$(DESTDIR)$(PREFIX)/include/" @@ -194,7 +200,7 @@ uninstall: -rm -f -- "$(DESTDIR)$(PREFIX)/include/libgamma.h" clean: - -rm -f -- *.o *.lo *.su *.a *.$(LIBEXT) + -rm -f -- *.o *.lo *.su *.a *.$(LIBEXT) test config.h .SUFFIXES: .SUFFIXES: .lo .o .c -- cgit v1.2.3-70-g09d2