Allow override of CFLAGS
If you attempt to specify your own CFLAGS on the command line (such as
make CFLAGS="--whatever"), this would prevent -DFIO_VERSION from being
added to CFLAGS. This patch uses the override directive to allow the
flag to be appended to CFLAGS.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
diff --git a/Makefile b/Makefile
index a4a478d..45b20e6 100644
--- a/Makefile
+++ b/Makefile
@@ -177,7 +177,7 @@
@$(SHELL) ./FIO-VERSION-GEN
-include FIO-VERSION-FILE
-CFLAGS += -DFIO_VERSION='"$(FIO_VERSION)"'
+override CFLAGS += -DFIO_VERSION='"$(FIO_VERSION)"'
.c.o: .depend FORCE
$(QUIET_CC)$(CC) -o $@ $(CFLAGS) $(CPPFLAGS) -c $<