blob: 055f21734551cc552ae416315cc2b64398cd7103 [file] [log] [blame]
# Copyright 2021 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/components.gni")
fuchsia_shell_package("tcpdump") {
deps = [ ":bin" ]
}
executable("bin") {
output_name = "tcpdump"
sources = [
"init.cc",
"src/addrtoname.c",
"src/addrtostr.c",
"src/af.c",
"src/ascii_strcasecmp.c",
"src/bpf_dump.c",
"src/checksum.c",
"src/cpack.c",
"src/fptype.c",
"src/gmpls.c",
"src/in_cksum.c",
"src/ipproto.c",
"src/l2vpn.c",
"src/machdep.c",
"src/netdissect-alloc.c",
"src/netdissect.c",
"src/nlpid.c",
"src/ntp.c",
"src/oui.c",
"src/parsenfsfh.c",
"src/print-802_11.c",
"src/print-802_15_4.c",
"src/print-ah.c",
"src/print-ahcp.c",
"src/print-aodv.c",
"src/print-aoe.c",
"src/print-ap1394.c",
"src/print-arcnet.c",
"src/print-arista.c",
"src/print-arp.c",
"src/print-ascii.c",
"src/print-atalk.c",
"src/print-atm.c",
"src/print-babel.c",
"src/print-bcm-li.c",
"src/print-beep.c",
"src/print-bfd.c",
"src/print-bgp.c",
"src/print-bootp.c",
"src/print-brcmtag.c",
"src/print-bt.c",
"src/print-calm-fast.c",
"src/print-carp.c",
"src/print-cdp.c",
"src/print-cfm.c",
"src/print-chdlc.c",
"src/print-cip.c",
"src/print-cnfp.c",
"src/print-dccp.c",
"src/print-decnet.c",
"src/print-dhcp6.c",
"src/print-domain.c",
"src/print-dsa.c",
"src/print-dtp.c",
"src/print-dvmrp.c",
"src/print-eap.c",
"src/print-egp.c",
"src/print-eigrp.c",
"src/print-enc.c",
"src/print-esp.c",
"src/print-ether.c",
"src/print-fddi.c",
"src/print-forces.c",
"src/print-fr.c",
"src/print-frag6.c",
"src/print-ftp.c",
"src/print-geneve.c",
"src/print-geonet.c",
"src/print-gre.c",
"src/print-hncp.c",
"src/print-hsrp.c",
"src/print-http.c",
"src/print-icmp.c",
"src/print-icmp6.c",
"src/print-igmp.c",
"src/print-igrp.c",
"src/print-ip-demux.c",
"src/print-ip.c",
"src/print-ip6.c",
"src/print-ip6opts.c",
"src/print-ipcomp.c",
"src/print-ipfc.c",
"src/print-ipnet.c",
"src/print-ipoib.c",
"src/print-ipx.c",
"src/print-isakmp.c",
"src/print-isoclns.c",
"src/print-juniper.c",
"src/print-krb.c",
"src/print-l2tp.c",
"src/print-lane.c",
"src/print-ldp.c",
"src/print-lisp.c",
"src/print-llc.c",
"src/print-lldp.c",
"src/print-lmp.c",
"src/print-loopback.c",
"src/print-lspping.c",
"src/print-lwapp.c",
"src/print-lwres.c",
"src/print-m3ua.c",
"src/print-macsec.c",
"src/print-mobile.c",
"src/print-mobility.c",
"src/print-mpcp.c",
"src/print-mpls.c",
"src/print-mptcp.c",
"src/print-msdp.c",
"src/print-msnlb.c",
"src/print-nflog.c",
"src/print-nsh.c",
"src/print-ntp.c",
"src/print-null.c",
"src/print-olsr.c",
"src/print-openflow-1.0.c",
"src/print-openflow-1.3.c",
"src/print-openflow.c",
"src/print-ospf.c",
"src/print-ospf6.c",
"src/print-otv.c",
"src/print-pgm.c",
"src/print-pim.c",
"src/print-pktap.c",
"src/print-ppi.c",
"src/print-ppp.c",
"src/print-pppoe.c",
"src/print-pptp.c",
"src/print-ptp.c",
"src/print-radius.c",
"src/print-raw.c",
"src/print-resp.c",
"src/print-rip.c",
"src/print-ripng.c",
"src/print-rpki-rtr.c",
"src/print-rrcp.c",
"src/print-rsvp.c",
"src/print-rt6.c",
"src/print-rtsp.c",
"src/print-rx.c",
"src/print-sctp.c",
"src/print-sflow.c",
"src/print-sip.c",
"src/print-sl.c",
"src/print-sll.c",
"src/print-slow.c",
"src/print-smb.c",
"src/print-smtp.c",
"src/print-snmp.c",
"src/print-someip.c",
"src/print-ssh.c",
"src/print-stp.c",
"src/print-sunatm.c",
"src/print-symantec.c",
"src/print-syslog.c",
"src/print-tcp.c",
"src/print-telnet.c",
"src/print-tftp.c",
"src/print-timed.c",
"src/print-tipc.c",
"src/print-token.c",
"src/print-udld.c",
"src/print-udp.c",
"src/print-unsupported.c",
"src/print-usb.c",
"src/print-vjc.c",
"src/print-vqp.c",
"src/print-vrrp.c",
"src/print-vsock.c",
"src/print-vtp.c",
"src/print-vxlan-gpe.c",
"src/print-vxlan.c",
"src/print-wb.c",
"src/print-zep.c",
"src/print-zephyr.c",
"src/print-zeromq.c",
"src/print.c",
"src/signature.c",
"src/smbutil.c",
"src/strtoaddr.c",
"src/tcpdump.c",
"src/util-print.c",
]
defines = [ "HAVE_CONFIG_H" ]
include_dirs = [
"./src",
# For config.h.
".",
]
configs += [ ":suppress_warnings" ]
deps = [
"//sdk/fidl/fuchsia.posix.socket.packet:fuchsia.posix.socket.packet_llcpp",
"//sdk/lib/vfs/cpp",
"//third_party/libpcap",
"//zircon/system/ulib/async-loop:async-loop-cpp",
"//zircon/system/ulib/async-loop:async-loop-default",
"//zircon/system/ulib/service:service-llcpp",
]
}
config("suppress_warnings") {
visibility = [ ":*" ]
cflags = [
"-Wno-incompatible-pointer-types-discards-qualifiers",
"-Wno-unused-but-set-variable",
"-Wno-implicit-int-conversion",
"-Wno-shorten-64-to-32",
"-Wno-implicit-float-conversion",
"-Wno-implicit-fallthrough",
"-Wno-unused-function",
"-Wno-deprecated-declarations",
]
}