From 3c41e5f7a276250b15a929f4935244fe115fb3f3 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Tue, 27 Feb 2024 20:07:13 -0300 Subject: Makefile: Centralize the definition of archive files --- Makefile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 18df8af..61ad077 100644 --- a/Makefile +++ b/Makefile @@ -58,6 +58,12 @@ fuzz.o = $(fuzz.c:.c=.o) fuzz.xa = $(fuzz.c:.c=.xa) fuzz.bin = $(fuzz.c:.c=.bin) +archives = \ + lib$(NAME).a \ + $(sources.xa) \ + src/main.xa \ + $(fuzz.xa) \ + sources = \ $(sources.c) \ $(sources.h) \ @@ -104,7 +110,7 @@ $(sources.o) $(sources.to): Makefile deps.mk src/config.h tests/slurp.o: Makefile deps.mk src/config.h -lib$(NAME).a $(sources.xa) src/main.xa $(fuzz.xa): +$(archives): $(AR) $(ARFLAGS) $@ $? src/catalog.bin-check: src/$(NAME).en.cat -- cgit v1.2.3