diff options
-rw-r--r-- | Config.mk | 2 | ||||
-rw-r--r-- | xen/tools/Makefile | 2 | ||||
-rw-r--r-- | xen/tools/symbols.c | 10 |
3 files changed, 7 insertions, 7 deletions
@@ -7,7 +7,7 @@ XEN_TARGET_X86_PAE ?= n # Tools to run on system hosting the build HOSTCC = gcc -HOSTCFLAGS = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer +HOSTCFLAGS = -Wall -Werror -Wstrict-prototypes -O2 -fomit-frame-pointer AS = $(CROSS_COMPILE)as LD = $(CROSS_COMPILE)ld diff --git a/xen/tools/Makefile b/xen/tools/Makefile index 04d7020cd8..4d353617bd 100644 --- a/xen/tools/Makefile +++ b/xen/tools/Makefile @@ -10,4 +10,4 @@ clean: rm -f *.o symbols symbols: symbols.c - $(HOSTCC) -o $@ $< + $(HOSTCC) $(HOSTCFLAGS) -o $@ $< diff --git a/xen/tools/symbols.c b/xen/tools/symbols.c index a5665cc124..7bc141e210 100644 --- a/xen/tools/symbols.c +++ b/xen/tools/symbols.c @@ -152,8 +152,8 @@ read_symbol(FILE *in, struct sym_entry *s) /* include the type field in the symbol name, so that it gets * compressed together */ s->len = strlen(str) + 1; - s->sym = (char *) malloc(s->len + 1); - strcpy(s->sym + 1, str); + s->sym = (unsigned char *) malloc(s->len + 1); + strcpy((char *)s->sym + 1, str); s->sym[0] = s->type; return 0; @@ -197,16 +197,16 @@ symbol_valid(struct sym_entry *s) * move then they may get dropped in pass 2, which breaks the * symbols rules. */ - if (s->addr == _etext && strcmp(s->sym + offset, "_etext")) + if (s->addr == _etext && strcmp((char *)s->sym + offset, "_etext")) return 0; } /* Exclude symbols which vary between passes. */ - if (strstr(s->sym + offset, "_compiled.")) + if (strstr((char *)s->sym + offset, "_compiled.")) return 0; for (i = 0; special_symbols[i]; i++) - if( strcmp(s->sym + offset, special_symbols[i]) == 0 ) + if( strcmp((char *)s->sym + offset, special_symbols[i]) == 0 ) return 0; return 1; |