From f4281cc49bf8448c6d808bc7cd84b9d4a9c927db Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Tue, 31 Dec 2002 21:14:21 +0000 Subject: [PATCH] 2002-12-31 Roland McGrath * Makerules (compile.S, COMPILE.S): Remove -DASSEMBLER here. Use $(S-CPPFLAGS) in place of $(asm-CPPFLAGS). (S-CPPFLAGS): Add -DASSEMBLER here instead. (generate-md5, +make-deps): Fix magic to get $(S-CPPFLAGS). --- Makerules | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Makerules b/Makerules index f4fed9f81f..ce208d3f64 100644 --- a/Makerules +++ b/Makerules @@ -370,16 +370,14 @@ endif # GCC can grok options after the file name, and it looks nicer that way. compile.c = $(CC) $< -c $(CFLAGS) $(CPPFLAGS) -compile.S = \ - $(CC) $< -c $(CPPFLAGS) -DASSEMBLER $(asm-CPPFLAGS) $(ASFLAGS-$(suffix $@)) -COMPILE.S = \ - $(CC) -c $(CPPFLAGS) -DASSEMBLER $(asm-CPPFLAGS) $(ASFLAGS-$(suffix $@)) +compile.S = $(CC) $< -c $(CPPFLAGS) $(S-CPPFLAGS) $(ASFLAGS-$(suffix $@)) +COMPILE.S = $(CC) -c $(CPPFLAGS) $(S-CPPFLAGS) $(ASFLAGS-$(suffix $@)) COMPILE.s = $(filter-out -pipe,$(CC)) -c $(ASFLAGS) # If we want to generate MD5 checksums for the sources do this now. ifeq ($(md5),yes) generate-md5 = ; rm -f $(@:.d=.md5); \ -$(CC) -E $< $(CFLAGS) $(CPPFLAGS) $($(<:$*.%=%)-CPPFLAGS) | \ +$(CC) -E $< $(CFLAGS) $(CPPFLAGS) $($(patsubst .%,%,$(suffix $( $(@:.d=.md5) else generate-md5 = @@ -393,11 +391,11 @@ OUTPUT_OPTION = -o $@ # We need the $(CFLAGS) to be in there to have the right predefines during # the dependency run for C sources. But having it for assembly sources can # get the wrong predefines. -S-CPPFLAGS = $(asm-CPPFLAGS) +S-CPPFLAGS = -DASSEMBLER $(asm-CPPFLAGS) define +make-deps $(make-target-directory) $(+mkdep) $< $(if $(filter %.c,$<),$(CFLAGS)) \ - $(CPPFLAGS) $($(<:$*.%=%)-CPPFLAGS) | sed \ + $(CPPFLAGS) $($(patsubst .%,%,$(suffix $( $(@:.d=.T) mv -f $(@:.d=.T) $@ $(generate-md5)