mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-18 10:35:55 +00:00
Automate options INET/INET6 turning into MK_$opt_SUPPORT
correctly. Fixes if_gfe when building without INET6 and simplifies if_gif's Makefile. Sponsored by: Netflix, Inc
This commit is contained in:
parent
5181481b9b
commit
8a3e6d90e5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=274529
@ -79,6 +79,18 @@ MK_${var}:= no
|
||||
.if defined(WITHOUT_${var}_SUPPORT) || ${MK_${var}} == "no"
|
||||
MK_${var}_SUPPORT:= no
|
||||
.else
|
||||
.if defined(KERNBUILDDIR) # See if there's an opt_foo.h
|
||||
OPT_${var}!= cat ${KERNBUILDDIR}/opt_${var:tl}.h; echo
|
||||
.if ${OPT_${var}} == "" # nothing -> no
|
||||
MK_${var}_SUPPORT:= no
|
||||
.else
|
||||
MK_${var}_SUPPORT:= yes
|
||||
.endif
|
||||
.else # otherwise, yes
|
||||
MK_${var}_SUPPORT:= yes
|
||||
.endif
|
||||
.endif
|
||||
.endfor
|
||||
|
||||
|
||||
|
||||
|
@ -8,13 +8,6 @@ SYSDIR?=${.CURDIR}/../..
|
||||
KMOD= if_gif
|
||||
SRCS= if_gif.c in_gif.c opt_inet.h opt_inet6.h
|
||||
|
||||
.if defined(KERNBUILDDIR)
|
||||
OPT_INET6!= cat ${KERNBUILDDIR}/opt_inet6.h; echo
|
||||
.if empty(OPT_INET6)
|
||||
MK_INET6_SUPPORT=no
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MK_INET6_SUPPORT} != "no"
|
||||
SRCS+= in6_gif.c
|
||||
.endif
|
||||
|
Loading…
Reference in New Issue
Block a user