linux-sparse.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] build: allow easy override of GCC_BASE
@ 2011-04-13 11:06 Diego Elio Pettenò
  2011-04-13 11:06 ` [PATCH 2/3] build: add an all-installable target that builds the targets to install Diego Elio Pettenò
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Diego Elio Pettenò @ 2011-04-13 11:06 UTC (permalink / raw)
  To: Linux-Sparse; +Cc: Diego Elio Pettenò

Sometimes gcc reports the wrong path for its own base (for instance when
ICC is present in the same system); by allowing an override of GCC_BASE in
Makefile, it's easier for packages to fix this up.
---
 Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/Makefile b/Makefile
index cc6176f..e08143a 100644
--- a/Makefile
+++ b/Makefile
@@ -21,7 +21,8 @@ HAVE_GCC_DEP:=$(shell touch .gcc-test.c && 				\
 		echo 'yes'; rm -f .gcc-test.d .gcc-test.o .gcc-test.c)
 HAVE_GTK2:=$(shell pkg-config --exists gtk+-2.0 2>/dev/null && echo 'yes')
 
-CFLAGS += -DGCC_BASE=\"$(shell $(CC) --print-file-name=)\"
+GCC_BASE = $(shell $(CC) --print-file-name=)
+CFLAGS += -DGCC_BASE=\"$(GCC_BASE)\"
 
 ifeq ($(HAVE_GCC_DEP),yes)
 CFLAGS += -Wp,-MD,$(@D)/.$(@F).d
-- 
1.7.5.rc1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-04-14  9:59 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-13 11:06 [PATCH 1/3] build: allow easy override of GCC_BASE Diego Elio Pettenò
2011-04-13 11:06 ` [PATCH 2/3] build: add an all-installable target that builds the targets to install Diego Elio Pettenò
2011-04-13 18:34   ` Josh Triplett
2011-04-13 18:35     ` Diego Elio Pettenò
2011-04-13 11:06 ` [PATCH 3/3] Fix build with GCC 4.6 series Diego Elio Pettenò
2011-04-14  9:58   ` Christopher Li
2011-04-14  9:59 ` [PATCH 1/3] build: allow easy override of GCC_BASE Christopher Li

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).