svn commit: r239264 - in head/sys/modules/cxgbe: if_cxgbe tom

Navdeep Parhar np at FreeBSD.org
Tue Aug 14 23:08:50 UTC 2012


Author: np
Date: Tue Aug 14 23:08:49 2012
New Revision: 239264
URL: http://svn.freebsd.org/changeset/base/239264

Log:
  Assume INET, INET6, and TCP_OFFLOAD when the driver is built out of tree and
  KERNBUILDDIR is not set.
  
  MFC after:	2 weeks

Modified:
  head/sys/modules/cxgbe/if_cxgbe/Makefile
  head/sys/modules/cxgbe/tom/Makefile

Modified: head/sys/modules/cxgbe/if_cxgbe/Makefile
==============================================================================
--- head/sys/modules/cxgbe/if_cxgbe/Makefile	Tue Aug 14 22:34:22 2012	(r239263)
+++ head/sys/modules/cxgbe/if_cxgbe/Makefile	Tue Aug 14 23:08:49 2012	(r239264)
@@ -2,6 +2,8 @@
 # $FreeBSD$
 #
 
+.include <bsd.own.mk>
+
 CXGBE = ${.CURDIR}/../../../dev/cxgbe
 .PATH: ${CXGBE} ${CXGBE}/common
 
@@ -17,4 +19,17 @@ CFLAGS+= -I${CXGBE}
 # Provide the timestamp of a packet in its header mbuf.
 #CFLAGS+= -DT4_PKT_TIMESTAMP
 
+.if !defined(KERNBUILDDIR)
+.if ${MK_INET_SUPPORT} != "no"
+opt_inet.h:
+	@echo "#define INET 1" > ${.TARGET}
+	@echo "#define TCP_OFFLOAD 1" >> ${.TARGET}
+.endif
+
+.if ${MK_INET6_SUPPORT} != "no"
+opt_inet6.h:
+	@echo "#define INET6 1" > ${.TARGET}
+.endif
+.endif
+
 .include <bsd.kmod.mk>

Modified: head/sys/modules/cxgbe/tom/Makefile
==============================================================================
--- head/sys/modules/cxgbe/tom/Makefile	Tue Aug 14 22:34:22 2012	(r239263)
+++ head/sys/modules/cxgbe/tom/Makefile	Tue Aug 14 23:08:49 2012	(r239264)
@@ -2,6 +2,8 @@
 # $FreeBSD$
 #
 
+.include <bsd.own.mk>
+
 CXGBE = ${.CURDIR}/../../../dev/cxgbe
 .PATH: ${CXGBE}/tom
 
@@ -12,4 +14,12 @@ SRCS+= opt_inet.h
 
 CFLAGS+= -I${CXGBE}
 
+.if !defined(KERNBUILDDIR)
+.if ${MK_INET_SUPPORT} != "no"
+opt_inet.h:
+	echo "#define INET 1" > ${.TARGET}
+	echo "#define TCP_OFFLOAD 1" >> ${.TARGET}
+.endif
+.endif
+
 .include <bsd.kmod.mk>


More information about the svn-src-head mailing list