Home | History | Annotate | Download | only in src
      1 # $FreeBSD: src/usr.sbin/ppp/Makefile,v 1.110.12.1 2010/12/21 17:10:29 kensmith Exp $
      2 
      3 .include <bsd.own.mk>
      4 
      5 PROG=	ppp
      6 MAN=	ppp.8
      7 SRCS=	acf.c arp.c async.c auth.c bundle.c cbcp.c ccp.c chap.c chat.c \
      8 	command.c datalink.c deflate.c defs.c exec.c filter.c fsm.c hdlc.c \
      9 	iface.c ip.c ipcp.c ipv6cp.c iplist.c lcp.c link.c log.c lqr.c main.c \
     10 	mbuf.c mp.c ncp.c ncpaddr.c pap.c physical.c pred.c probe.c prompt.c \
     11 	proto.c route.c server.c sig.c slcompress.c sync.c systems.c tcp.c \
     12 	tcpmss.c throughput.c timer.c tty.c tun.c udp.c vjcomp.c
     13 WARNS?=	3
     14 .if defined(RELEASE_CRUNCH)
     15 CFLAGS+=-DRELEASE_CRUNCH
     16 PPP_NO_ATM=
     17 PPP_NO_DES=
     18 PPP_NO_I4B=
     19 PPP_NO_KLDLOAD=
     20 PPP_NO_NAT=
     21 PPP_NO_PAM=
     22 PPP_NO_RADIUS=
     23 PPP_NO_SUID=
     24 .endif
     25 
     26 .if ${MK_ATM} == "no"
     27 PPP_NO_ATM=
     28 .endif
     29 .if ${MK_I4B} == "no"
     30 PPP_NO_I4B=
     31 .endif
     32 .if ${MK_PAM_SUPPORT} == "no"
     33 PPP_NO_PAM=
     34 .endif
     35 
     36 .if defined(PPP_NO_SUID)
     37 BINMODE=550
     38 .else
     39 BINMODE=4550
     40 BINOWN=	root
     41 .endif
     42 BINGRP=	network
     43 M4FLAGS=
     44 
     45 LDADD= -lcrypt -lmd -lutil -lz
     46 DPADD=	${LIBCRYPT} ${LIBMD} ${LIBUTIL} ${LIBZ}
     47 
     48 .SUFFIXES: .8 .8.m4
     49 
     50 .8.m4.8:
     51 	m4 ${M4FLAGS} ${.IMPSRC} >${.TARGET}
     52 
     53 CLEANFILES= ppp.8
     54 
     55 .if defined(PPP_CONFDIR) && !empty(PPP_CONFDIR)
     56 CFLAGS+=-DPPP_CONFDIR=\"${PPP_CONFDIR}\"
     57 .endif
     58 
     59 .if defined(PPP_NO_KLDLOAD)
     60 CFLAGS+=-DNOKLDLOAD
     61 .endif
     62 
     63 .if ${MK_INET6_SUPPORT} == "no"
     64 CFLAGS+=-DNOINET6
     65 .endif
     66 
     67 .if defined(PPP_NO_NAT)
     68 CFLAGS+=-DNONAT
     69 .else
     70 SRCS+=	nat_cmd.c
     71 LDADD+=	-lalias
     72 DPADD+= ${LIBALIAS}
     73 .endif
     74 
     75 .if defined(PPP_NO_ATM)
     76 CFLAGS+=-DNOATM
     77 .else
     78 SRCS+=	atm.c
     79 .endif
     80 
     81 .if defined(PPP_NO_SUID)
     82 CFLAGS+=-DNOSUID
     83 .else
     84 SRCS+=	id.c
     85 .endif
     86 
     87 .if defined(RELEASE_CRUNCH) || ${MK_OPENSSL} == "no" || \
     88     defined(PPP_NO_DES)
     89 CFLAGS+=-DNODES
     90 .else
     91 SRCS+=	chap_ms.c mppe.c
     92 LDADD+= -lcrypto
     93 DPADD+= ${LIBCRYPTO}
     94 .endif
     95 
     96 .if defined(PPP_NO_RADIUS)
     97 CFLAGS+=-DNORADIUS
     98 .else
     99 SRCS+=	radius.c
    100 LDADD+=	-lradius
    101 DPADD+= ${LIBRADIUS}
    102 .endif
    103 
    104 .if defined(PPP_NO_I4B) || ${MACHINE_ARCH} != "i386"
    105 CFLAGS+=-DNOI4B
    106 .else
    107 SRCS+=	i4b.c
    108 .endif
    109 
    110 .if defined(PPP_NO_NETGRAPH)
    111 CFLAGS+=-DNONETGRAPH
    112 .else
    113 SRCS+=	ether.c
    114 LDADD+=	-lnetgraph
    115 DPADD+= ${LIBNETGRAPH}
    116 .if defined(EXPERIMENTAL_NETGRAPH)
    117 CFLAGS+=-DEXPERIMENTAL_NETGRAPH
    118 SRCS+=	netgraph.c
    119 .endif
    120 .endif
    121 
    122 .if defined(PPP_NO_PAM)
    123 CFLAGS+=-DNOPAM
    124 .else
    125 LDADD+=	${MINUSLPAM}
    126 DPADD+=	${LIBPAM}
    127 .endif
    128 
    129 .include <bsd.prog.mk>
    130