blob: 1582956988ffd4420efccfb76010fb2d893f4530 [file] [log] [blame]
# chrony NTP daemon
#
# From the chrony website (https://chrony.tuxfamily.org/):
#
# chrony is a versatile implementation of the Network Time
# Protocol (NTP). It can synchronise the system clock with NTP servers,
# reference clocks (e.g. GPS receiver), and manual input using
# wristwatch and keyboard. It can also operate as an NTPv4 (RFC 5905)
# server and peer to provide a time service to other computers in the
# network.
# config.h created with ./configure --without-readline \
# --without-editline --without-libcap --without-nss
licenses(["restricted"])
package(default_visibility = ["//third_party/chrony:internal"])
cc_library(
name = "chrony_headers",
textual_hdrs = glob(["*.h"]) + ["md5.c"],
)
cc_binary(
name = "chronyd",
srcs = [
"addrfilt.c",
"array.c",
"clientlog.c",
"cmdmon.c",
"cmdparse.c",
"conf.c",
"hash_intmd5.c",
"hwclock.c",
"keys.c",
"local.c",
"logging.c",
"main.c",
"manual.c",
"memory.c",
"nameserv.c",
"nameserv_async.c",
"ntp_auth.c",
"ntp_core.c",
"ntp_ext.c",
"ntp_io.c",
"ntp_io_linux.c",
"ntp_sources.c",
"pktlength.c",
"refclock.c",
"refclock_phc.c",
"refclock_pps.c",
"refclock_shm.c",
"refclock_sock.c",
"reference.c",
"regress.c",
"rtc.c",
"rtc_linux.c",
"samplefilt.c",
"sched.c",
"smooth.c",
"socket.c",
"sources.c",
"sourcestats.c",
"stubs.c",
"sys.c",
"sys_generic.c",
"sys_linux.c",
"sys_null.c",
"sys_posix.c",
"sys_timex.c",
"tempcomp.c",
"util.c",
],
copts = [
# all instances are of the form
# default: assert(0)
"-Wno-error",
],
defines = select({
"//tools/cc_target_os:chromiumos": [],
"//conditions:default": ["HAVE_LONG_TIME_T"],
}),
deps = [
":chrony_headers",
],
)
cc_binary(
name = "chronyc",
srcs = [
"array.c",
"client.c",
"cmdparse.c",
"getdate.c",
"hash_intmd5.c",
"memory.c",
"nameserv.c",
"pktlength.c",
"socket.c",
"util.c",
],
defines = select({
"//tools/cc_target_os:chromiumos": [],
"//conditions:default": ["HAVE_LONG_TIME_T"],
}),
deps = [
":chrony_headers",
],
)