diff options
-rw-r--r-- | sys/conf/Makefile.alpha | 2 | ||||
-rw-r--r-- | sys/conf/Makefile.i386 | 2 | ||||
-rw-r--r-- | sys/conf/Makefile.ia64 | 2 | ||||
-rw-r--r-- | sys/conf/Makefile.pc98 | 2 | ||||
-rw-r--r-- | sys/conf/Makefile.powerpc | 2 | ||||
-rw-r--r-- | sys/conf/Makefile.sparc64 | 2 | ||||
-rw-r--r-- | sys/conf/kern.pre.mk | 14 | ||||
-rw-r--r-- | usr.sbin/config/config.h | 1 | ||||
-rw-r--r-- | usr.sbin/config/configvers.h | 2 | ||||
-rw-r--r-- | usr.sbin/config/mkmakefile.c | 14 |
10 files changed, 29 insertions, 14 deletions
diff --git a/sys/conf/Makefile.alpha b/sys/conf/Makefile.alpha index c744f5e..4ccb876 100644 --- a/sys/conf/Makefile.alpha +++ b/sys/conf/Makefile.alpha @@ -17,7 +17,7 @@ # # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 .if !defined(S) .if exists(./@/.) diff --git a/sys/conf/Makefile.i386 b/sys/conf/Makefile.i386 index 2341789..51d2afb 100644 --- a/sys/conf/Makefile.i386 +++ b/sys/conf/Makefile.i386 @@ -17,7 +17,7 @@ # # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 STD8X16FONT?= iso diff --git a/sys/conf/Makefile.ia64 b/sys/conf/Makefile.ia64 index fbccd26..20eddd1 100644 --- a/sys/conf/Makefile.ia64 +++ b/sys/conf/Makefile.ia64 @@ -30,7 +30,7 @@ MACHINE_ARCH= ia64 FMT= # Needs to be blank for linux cross tools. # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 STD8X16FONT?= iso diff --git a/sys/conf/Makefile.pc98 b/sys/conf/Makefile.pc98 index 5373c0e..9330d8d 100644 --- a/sys/conf/Makefile.pc98 +++ b/sys/conf/Makefile.pc98 @@ -19,7 +19,7 @@ # # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 .if !defined(S) .if exists(./@/.) diff --git a/sys/conf/Makefile.powerpc b/sys/conf/Makefile.powerpc index 9d228ea..31dfd1b 100644 --- a/sys/conf/Makefile.powerpc +++ b/sys/conf/Makefile.powerpc @@ -17,7 +17,7 @@ # # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 # Temporary stuff while we're still embryonic NO_MODULES?= yes diff --git a/sys/conf/Makefile.sparc64 b/sys/conf/Makefile.sparc64 index 88d3a05..1dfd1d5 100644 --- a/sys/conf/Makefile.sparc64 +++ b/sys/conf/Makefile.sparc64 @@ -36,7 +36,7 @@ CWARNFLAGS= -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \ FMT= # Which version of config(8) is required. -%VERSREQ= 500009 +%VERSREQ= 500010 STD8X16FONT?= iso diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index 2753418..261025f 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -58,14 +58,20 @@ PROF+= -mprofiler-epilogue .endif .endif +#.if defined(NO_WERROR) +#WERROR= +#.else +#WERROR?= -Werror +#.endif + # Put configuration-specific C flags last (except for ${PROF}) so that they # can override the others. CFLAGS+= ${CONF_CFLAGS} -NORMAL_C= ${CC} -c ${CFLAGS} ${PROF} ${.IMPSRC} -NORMAL_C_C= ${CC} -c ${CFLAGS} ${PROF} ${.IMPSRC} -NORMAL_S= ${CC} -c ${ASM_CFLAGS} ${.IMPSRC} -PROFILE_C= ${CC} -c ${CFLAGS} ${.IMPSRC} +NORMAL_C= ${CC} -c ${CFLAGS} ${WERROR} ${PROF} ${.IMPSRC} +NORMAL_S= ${CC} -c ${ASM_CFLAGS} ${WERROR} ${.IMPSRC} +PROFILE_C= ${CC} -c ${CFLAGS} ${WERROR} ${.IMPSRC} +NORMAL_C_NOWERROR= ${CC} -c ${CFLAGS} ${PROF} ${.IMPSRC} NORMAL_M= perl5 $S/kern/makeobjops.pl -c $<; \ ${CC} -c ${CFLAGS} ${PROF} ${.PREFIX}.c diff --git a/usr.sbin/config/config.h b/usr.sbin/config/config.h index 7c493d8..02df879 100644 --- a/usr.sbin/config/config.h +++ b/usr.sbin/config/config.h @@ -72,6 +72,7 @@ struct file_list { #define BEFORE_DEPEND 4 #define NEED_COUNT 8 #define ISDUP 16 +#define NOWERROR 32 struct device { int d_done; /* processed */ diff --git a/usr.sbin/config/configvers.h b/usr.sbin/config/configvers.h index 6455f5d..fcc7265 100644 --- a/usr.sbin/config/configvers.h +++ b/usr.sbin/config/configvers.h @@ -8,4 +8,4 @@ * * $FreeBSD$ */ -#define CONFIGVERS 500009 +#define CONFIGVERS 500010 diff --git a/usr.sbin/config/mkmakefile.c b/usr.sbin/config/mkmakefile.c index dda72b6..c24a121 100644 --- a/usr.sbin/config/mkmakefile.c +++ b/usr.sbin/config/mkmakefile.c @@ -317,7 +317,7 @@ read_files(void) char *wd, *this, *needs, *compilewith, *depends, *clean, *warning; char fname[MAXPATHLEN]; int nreqs, first = 1, isdup, std, filetype, - imp_rule, no_obj, needcount, before_depend, mandatory; + imp_rule, no_obj, needcount, before_depend, mandatory, nowerror; ftab = 0; if (ident == NULL) { @@ -384,6 +384,7 @@ next: no_obj = 0; needcount = 0; before_depend = 0; + nowerror = 0; filetype = NORMAL; if (eq(wd, "standard")) { std = 1; @@ -475,6 +476,10 @@ nextparam: filetype = PROFILING; goto nextparam; } + if (eq(wd, "nowerror")) { + nowerror = 1; + goto nextparam; + } if (needs == 0 && nreqs == 1) needs = ns(wd); if (isdup) @@ -547,6 +552,8 @@ doneparam: tp->f_flags |= BEFORE_DEPEND; if (needcount) tp->f_flags |= NEED_COUNT; + if (nowerror) + tp->f_flags |= NOWERROR; tp->f_needs = needs; tp->f_compilewith = compilewith; tp->f_depends = depends; @@ -736,8 +743,9 @@ do_rules(FILE *f) printf("config: don't know rules for %s\n", np); break; } - snprintf(cmd, sizeof(cmd), "${%s_%c}", ftype, - toupper(och)); + snprintf(cmd, sizeof(cmd), "${%s_%c%s}", ftype, + toupper(och), + ftp->f_flags & NOWERROR ? "_NOWERROR" : ""); compilewith = cmd; } *cp = och; |