freebsd-dev/sbin/ping/Makefile
Alan Somers fd26389be7 ping: allow building without INET support
Building without INET6 support was already possible. Now it's possible to
build ping with only INET6, or even with neither INET nor INET6.

Reported by:	bz
Reviewed by:	bz
MFC-With:	368045
Differential Revision:	https://reviews.freebsd.org/D27394
2020-11-28 23:24:19 +00:00

41 lines
659 B
Makefile

# @(#)Makefile 8.1 (Berkeley) 6/5/93
# $FreeBSD$
.include <src.opts.mk>
PACKAGE=runtime
PROG= ping
SRCS= main.c
MAN= ping.8
BINOWN= root
BINMODE=4555
LIBADD= m
.if ${MK_INET_SUPPORT}!= "no"
CFLAGS+= -DINET
SRCS+= ping.c utils.c
.endif
.if ${MK_INET6_SUPPORT} != "no"
CFLAGS+= -DINET6 -DKAME_SCOPEID
SRCS+= ping6.c
LIBADD+= md
LINKS= ${BINDIR}/ping ${BINDIR}/ping6
.endif
.if ${MK_DYNAMICROOT} == "no"
.warning ${PROG} built without libcasper support
.elif ${MK_CASPER} != "no" && !defined(RESCUE)
LIBADD+= casper
LIBADD+= cap_dns
CFLAGS+=-DWITH_CASPER
.endif
CFLAGS+=-DIPSEC
LIBADD+= ipsec
HAS_TESTS=
SUBDIR.${MK_TESTS}+= tests
.include <bsd.prog.mk>