chiark / gitweb /
Introduce CDEPS_CFLAGS so without cdeps.sd.mk you don't get .*.d
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 13 Nov 2019 22:04:32 +0000 (22:04 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 13 Nov 2019 22:12:25 +0000 (22:12 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
subdirmk/cdeps.sd.mk
subdirmk/usual.mk.in

index c898cc0..6ba0bbb 100644 (file)
@@ -3,6 +3,8 @@
 #  Copyright 2019 Ian Jackson
 # SPDX-License-Identifier: LGPL-2.0-or-later
 
+CDEPS_CFLAGS ?= -MD -MF $(*D)/.$(*F).d
+
 &DEPFILES += $(foreach b,$(patsubst %.o,%,$(&OBJECTS)), \
                $(dir $b).$(notdir $b).d)
 -include $(&DEPFILES)
index 97f99e7..c40a18f 100644 (file)
@@ -19,7 +19,7 @@ LIBS          ?= @LIBS@
 
 LINK           ?= $(CC) -o$@ $(CFLAGS) $(LDFLAGS)
 AR             ?= ar
-COMPILE                ?= $(CC) -c -o$@ -MD -MF $(*D)/.$(*F).d $(DEFS) $(INCLUDES) $(CFLAGS)
+COMPILE                ?= $(CC) -c -o$@ $(CDEPS_CFLAGS) $(DEFS) $(INCLUDES) $(CFLAGS)
 
 %.o: %.c
        $(COMPILE) $<