build: allow easy override of GCC_BASE
Subsystems (2)
PATCH 1/3 build: allow easy override of GCC_BASE
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(-)
Makefile +2 -1
@@ -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
Signature · 1 line
1.7.5.rc1
PATCH 2/3 build: add an all-installable target that builds the targets to install.
This is useful for distributions that don't want to build content that won't be installed.
--- Makefile | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
Makefile +3 -1
@@ -118,7 +118,9 @@ SED_PC_CMD = 's|@version@|$(VERSION)|g; \ all: $(PROGRAMS) sparse.pc -install: $(INST_PROGRAMS) $(LIBS) $(LIB_H) sparse.pc +all-installable: $(INST_PROGRAMS) $(LIBS) $(LIB_H) sparse.pc + +install: all-installable $(Q)install -d $(DESTDIR)$(BINDIR) $(Q)install -d $(DESTDIR)$(LIBDIR) $(Q)install -d $(DESTDIR)$(MAN1DIR)
Signature · 1 line
1.7.5.rc1
Re: [PATCH 2/3] build: add an all-installable target that builds the targets to install.
Quoted 11 lines · Diego Elio Pettenò
This is useful for distributions that don't want to build content that won't be installed.
--- Makefile | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)Makefile +0
-0
Makefile SED_PC_CMD = 's|@version@|$(VERSION)|g; \ · line 126
Quoted 10 lines
Makefile +3
-1@@ -118,7 +118,9 @@ SED_PC_CMD = 's|@version@|$(VERSION)|g; \ all: $(PROGRAMS) sparse.pc -install: $(INST_PROGRAMS) $(LIBS) $(LIB_H) sparse.pc +all-installable: $(INST_PROGRAMS) $(LIBS) $(LIB_H) sparse.pc + +install: all-installable $(Q)install -d $(DESTDIR)$(BINDIR) $(Q)install -d $(DESTDIR)$(LIBDIR) $(Q)install -d $(DESTDIR)$(MAN1DIR)
Why not just "make install" instead? You don't have to separately make and make install; make install will build all the installed programs and then install them.
- Josh Triplett
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH 2/3] build: add an all-installable target that builds the targets to install.
Il giorno mer, 13/04/2011 alle 11.34 -0700, Josh Triplett ha scritto:
Quoted 6 lines
Why not just "make install" instead? You don't have to separately make
and make install; make install will build all the installed programs and
then install them.
Most distributions – including Gentoo – prefer running the steps separately, adding safety checks between one step and the other.
Signature · 7 lines
Diego Elio Pettenò — Flameeyes http://blog.flameeyes.eu/ -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH 3/3 Fix build with GCC 4.6 series.
In reply to Diego Elio PettenòThe label_statement attribute in the anonymous structures' union was duplicated for label_arg and labeled_struct alises, which were identical. Since the former is never used, delete it and leave the other as the only copy.
--- parse.h | 4 ---- 1 files changed, 0 insertions(+), 4 deletions(-)
parse.h +0 -4
@@ -35,10 +35,6 @@ struct statement {struct /* declaration */ {struct symbol_list *declaration; }; -struct /* label_arg */ { -struct symbol *label; -struct statement *label_statement; - };struct {struct expression *expression;struct expression *context;
Signature · 1 line
1.7.5.rc1
Christopher Li
maintainerRe: [PATCH 3/3] Fix build with GCC 4.6 series.
Will apply.
Chris
Quoted 26 lines · Diego Elio Pettenò
The
label_statementattribute in the anonymous structures' union was duplicated forlabel_argandlabeled_structalises, which were identical. Since the former is never used, delete it and leave the other as the only copy.
---
parse.h | 4 ----1 files changed, 0 insertions(+), 4 deletions(-)parse.h +0
-5@@ -35,10 +35,6 @@ struct statement { struct /* declaration */ { struct symbol_list *declaration; }; - struct /* label_arg */ { - struct symbol *label; - struct statement *label_statement; - }; struct { struct expression *expression; struct expression *context; --1.7.5.rc1
Quoted 5 lines
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Christopher Li
maintainerWill apply.
Chris
Quoted 24 lines · 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_BASEinMakefile, it's easier for packages to fix this up.
---
Makefile | 3 ++-1 files changed, 2 insertions(+), 1 deletions(-)Makefile +2
-1@@ -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
Quoted 5 lines
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html