Merge from vendor branch GROFF:
[dragonfly.git] / sys / net / ef / Makefile
1 # $FreeBSD: src/sys/modules/if_ef/Makefile,v 1.2.2.2 2001/04/25 11:24:03 ru Exp $
2 # $DragonFly: src/sys/net/ef/Makefile,v 1.3 2005/02/18 11:41:42 corecode Exp $
3
4 .PATH:  ${.CURDIR}/../../net
5
6 KMOD=   if_ef
7 SRCS=   if_ef.c opt_ipx.h opt_inet.h opt_ef.h
8 MAN=    ef.4
9
10 # If you need only limited number of frames comment out unneeded ones
11 # this will reduce number of visible devices
12 ETHER_II=
13 ETHER_8023=
14 ETHER_8022=
15 ETHER_SNAP=
16
17 CFLAGS+= ${PROTOS}
18
19 .if defined(EFDEBUG)
20 CFLAGS+= -DEF_DEBUG
21 .endif
22
23 .if !defined(BUILDING_WITH_KERNEL)
24 opt_inet.h:
25         echo "#define INET 1" > opt_inet.h
26
27 opt_ipx.h:
28         echo "#define IPX 1" > opt_ipx.h
29 .endif
30
31 opt_ef.h:
32 .for frame in ETHER_II ETHER_8023 ETHER_8022 ETHER_SNAP
33 .if defined(${frame})
34         echo "#define ${frame} 1" >> opt_ef.h
35 .endif
36 .endfor
37
38 load: all
39         /sbin/kldload ${.OBJDIR}/${KMOD}
40
41 unload:
42         -/sbin/kldunload ${KMOD}
43
44 .include <bsd.kmod.mk>