Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Jul 2015 10:26:44 +0000 (UTC)
From:      "Andrey V. Elsukov" <ae@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r286069 - in head/sys: modules modules/if_stf net
Message-ID:  <201507301026.t6UAQi53067370@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ae
Date: Thu Jul 30 10:26:43 2015
New Revision: 286069
URL: https://svnweb.freebsd.org/changeset/base/286069

Log:
  Build if_stf(4) module only when both INET and INET6 support are enabled.

Modified:
  head/sys/modules/Makefile
  head/sys/modules/if_stf/Makefile
  head/sys/net/if_stf.c

Modified: head/sys/modules/Makefile
==============================================================================
--- head/sys/modules/Makefile	Thu Jul 30 10:09:31 2015	(r286068)
+++ head/sys/modules/Makefile	Thu Jul 30 10:26:43 2015	(r286069)
@@ -149,7 +149,7 @@ SUBDIR=	\
 	${_if_me} \
 	if_lagg \
 	${_if_ndis} \
-	if_stf \
+	${_if_stf} \
 	if_tap \
 	if_tun \
 	if_vlan \
@@ -411,6 +411,11 @@ _if_gif=	if_gif
 _if_gre=	if_gre
 .endif
 
+.if (${MK_INET_SUPPORT} != "no" && ${MK_INET6_SUPPORT} != "no") || \
+	defined(ALL_MODULES)
+_if_stf=	if_stf
+.endif
+
 .if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES)
 _if_me=		if_me
 _ipdivert=	ipdivert

Modified: head/sys/modules/if_stf/Makefile
==============================================================================
--- head/sys/modules/if_stf/Makefile	Thu Jul 30 10:09:31 2015	(r286068)
+++ head/sys/modules/if_stf/Makefile	Thu Jul 30 10:26:43 2015	(r286069)
@@ -3,6 +3,6 @@
 .PATH: ${.CURDIR}/../../net
 
 KMOD=	if_stf
-SRCS=	if_stf.c opt_inet.h opt_inet6.h
+SRCS=	if_stf.c
 
 .include <bsd.kmod.mk>

Modified: head/sys/net/if_stf.c
==============================================================================
--- head/sys/net/if_stf.c	Thu Jul 30 10:09:31 2015	(r286068)
+++ head/sys/net/if_stf.c	Thu Jul 30 10:26:43 2015	(r286069)
@@ -74,9 +74,6 @@
  * Note that there is no way to be 100% secure.
  */
 
-#include "opt_inet.h"
-#include "opt_inet6.h"
-
 #include <sys/param.h>
 #include <sys/systm.h>
 #include <sys/socket.h>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201507301026.t6UAQi53067370>