When compiling with the kernel, detect if INET6 support should be disabled.
This commit is contained in:
parent
ae00167101
commit
81478391e3
@ -5,13 +5,8 @@
|
||||
KMOD= if_gif
|
||||
SRCS= if_gif.c in_gif.c opt_inet.h opt_inet6.h opt_mac.h \
|
||||
opt_mrouting.h
|
||||
.if !defined(NO_INET6)
|
||||
SRCS+= in6_gif.c
|
||||
.endif
|
||||
|
||||
# XXX The new way of building modules with the kernel can't handle
|
||||
# dynamic SRCS depending on build options yet.
|
||||
##.if !defined(KERNBUILDDIR)
|
||||
.if !defined(KERNBUILDDIR)
|
||||
opt_inet.h:
|
||||
echo "#define INET 1" > ${.TARGET}
|
||||
|
||||
@ -22,6 +17,15 @@ opt_inet6.h:
|
||||
|
||||
opt_mrouting.h:
|
||||
echo "#define MROUTING 1" > ${.TARGET}
|
||||
##.endif
|
||||
.else
|
||||
OPT_INET6!= cat ${KERNBUILDDIR}/opt_inet6.h
|
||||
.if empty(OPT_INET6)
|
||||
NO_INET6=
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if !defined(NO_INET6)
|
||||
SRCS+= in6_gif.c
|
||||
.endif
|
||||
|
||||
.include <bsd.kmod.mk>
|
||||
|
Loading…
Reference in New Issue
Block a user