diff options
author | archie <archie@FreeBSD.org> | 2000-04-10 22:22:18 +0000 |
---|---|---|
committer | archie <archie@FreeBSD.org> | 2000-04-10 22:22:18 +0000 |
commit | 1f9a3b6ffeeb06ce3881cbb6016adb4f15ef9d81 (patch) | |
tree | 0b067b4dea5a9b564182833ac21703608208c962 | |
parent | 1c9e14061b668928d6ea46d5c6ae97533a7a4880 (diff) | |
download | FreeBSD-src-1f9a3b6ffeeb06ce3881cbb6016adb4f15ef9d81.zip FreeBSD-src-1f9a3b6ffeeb06ce3881cbb6016adb4f15ef9d81.tar.gz |
Turn off MPPE encryption if NOCRYPT is defined. If neither compression
nor encryption is enabled, don't build or install anything.
-rw-r--r-- | sys/modules/netgraph/mppc/Makefile | 29 |
1 files changed, 22 insertions, 7 deletions
diff --git a/sys/modules/netgraph/mppc/Makefile b/sys/modules/netgraph/mppc/Makefile index 730644b..4c7b031 100644 --- a/sys/modules/netgraph/mppc/Makefile +++ b/sys/modules/netgraph/mppc/Makefile @@ -1,14 +1,29 @@ # $Whistle: Makefile,v 1.1 1999/12/08 20:20:39 archie Exp $ # $FreeBSD$ +# Determine which of compression and encryption to support +# +NETGRAPH_MPPC_COMPRESSION?= 0 +.if !defined(NETGRAPH_MPPC_ENCRYPTION) +.if defined(NOCRYPT) +NETGRAPH_MPPC_ENCRYPTION= 0 +.else +NETGRAPH_MPPC_ENCRYPTION= 1 +.endif +.endif + +# No point in building module if neither is enabled +# +.if ${NETGRAPH_MPPC_COMPRESSION} == 0 && ${NETGRAPH_MPPC_ENCRYPTION} == 0 +all depend distribute install load unload: + @echo '>>>' Neither compression nor encryption enabled, skipping KLD netgraph/mppc. +.else + KMOD= ng_mppc SRCS= ng_mppc.c opt_netgraph.h MAN8= ng_mppc.8 KMODDEPS= netgraph -NETGRAPH_MPPC_COMPRESSION?= 0 -NETGRAPH_MPPC_ENCRYPTION?= 1 - CFLAGS+= ${PROTOS} CLEANFILES+= opt_netgraph.h @@ -16,10 +31,13 @@ CLEANFILES+= opt_netgraph.h .if ${NETGRAPH_MPPC_COMPRESSION} > 0 # XXX These files don't exist yet, but hopefully someday they will... SRCS+= mppcc.c mppcd.c +.PATH: ${.CURDIR}/../../../net .endif .if ${NETGRAPH_MPPC_ENCRYPTION} > 0 SRCS+= rc4.c sha1.c +.PATH: ${.CURDIR}/../../../crypto +.PATH: ${.CURDIR}/../../../crypto/rc4 .endif opt_netgraph.h: @@ -31,8 +49,5 @@ opt_netgraph.h: echo "#define NETGRAPH_MPPC_ENCRYPTION 1" >> ${.TARGET} .endif -.PATH: ${.CURDIR}/../../../net -.PATH: ${.CURDIR}/../../../crypto -.PATH: ${.CURDIR}/../../../crypto/rc4 - .include <bsd.kmod.mk> +.endif |