Define HAVE_KERNEL_OPTION_HEADERS when building kernel and when building

modules along with kernel.

After this change it is possible to embrace opt_*.h includes with ifdef
HAVE_KERNEL_OPTION_HEADERS. And thus, avoid editing a lot of Makefiles
in modules directory each time we introduce a new opt_xxx.h.

Requested by:	bde
This commit is contained in:
glebius 2005-10-05 10:05:55 +00:00
parent a358b1f631
commit e2de919bb5
2 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@ INCLUDES+= -I$S/dev/twa
.endif
CFLAGS= ${COPTFLAGS} ${CWARNFLAGS} ${DEBUG}
CFLAGS+= ${INCLUDES} -D_KERNEL -include opt_global.h
CFLAGS+= ${INCLUDES} -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h
.if ${CC} != "icc"
CFLAGS+= -fno-common -finline-limit=${INLINE_LIMIT}
CFLAGS+= --param inline-unit-growth=100

View File

@ -91,7 +91,7 @@ NOSTDINC= -nostdinc
.endif
CFLAGS+= ${NOSTDINC} -I- ${INCLMAGIC} ${_ICFLAGS}
.if defined(KERNBUILDDIR)
CFLAGS+= -include ${KERNBUILDDIR}/opt_global.h
CFLAGS+= -DHAVE_KERNEL_OPTION_HEADERS -include ${KERNBUILDDIR}/opt_global.h
.endif
# Add -I paths for system headers. Individual module makefiles don't